﻿using System;
using System.Data;
using System.Data.SqlClient;
using System.Collections;

using Shove.Database;

namespace DAL
{
    /*
    Program Name: Shove.DAL.30
    Program Version: 3.0
    Writer By: 3km.shovesoft.shove (zhou changjun)
    Release Time: 2008.9.1

    System Request: Shove.dll
    All Rights saved.
    */


    // Please Add a Key in Web.config File's appSetting section, Exemple:
    // <add key="ConnectionString" value="server=(local);User id=sa;Pwd=;Database=master" />


    public class Tables
    {
        public class tbl_CustomerConsumer : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field Money;
            public MSSQL.Field DateTime;
            public MSSQL.Field isBalanced;

            public tbl_CustomerConsumer()
            {
                TableName = "tbl_CustomerConsumer";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                isBalanced = new MSSQL.Field(this, "isBalanced", "isBalanced", SqlDbType.Bit, false);
            }
        }

        public class tbl_Shop_GoodPropertyValue : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field GoodID;
            public MSSQL.Field PropertyID;
            public MSSQL.Field PropertyValue;

            public tbl_Shop_GoodPropertyValue()
            {
                TableName = "tbl_Shop_GoodPropertyValue";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                PropertyID = new MSSQL.Field(this, "PropertyID", "PropertyID", SqlDbType.BigInt, false);
                PropertyValue = new MSSQL.Field(this, "PropertyValue", "PropertyValue", SqlDbType.NVarChar, false);
            }
        }

        public class tbl_Shop_GoodProperty : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field PropertyName;

            public tbl_Shop_GoodProperty()
            {
                TableName = "tbl_Shop_GoodProperty";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                PropertyName = new MSSQL.Field(this, "PropertyName", "PropertyName", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Earning3 : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field PV;
            public MSSQL.Field Percent;
            public MSSQL.Field Bouns;
            public MSSQL.Field IsDistill;

            public tbl_Earning3()
            {
                TableName = "tbl_Earning3";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                Percent = new MSSQL.Field(this, "Percent", "Percent", SqlDbType.Float, false);
                Bouns = new MSSQL.Field(this, "Bouns", "Bouns", SqlDbType.Money, false);
                IsDistill = new MSSQL.Field(this, "IsDistill", "IsDistill", SqlDbType.Bit, false);
            }
        }

        public class tbl_Site_GoodComment : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopStockID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field Title;
            public MSSQL.Field Content;
            public MSSQL.Field ReplyDate;
            public MSSQL.Field ReplyContent;
            public MSSQL.Field Type;
            public MSSQL.Field ShopID;

            public tbl_Site_GoodComment()
            {
                TableName = "tbl_Site_GoodComment";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopStockID = new MSSQL.Field(this, "ShopStockID", "ShopStockID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                Title = new MSSQL.Field(this, "Title", "Title", SqlDbType.VarChar, false);
                Content = new MSSQL.Field(this, "Content", "Content", SqlDbType.VarChar, false);
                ReplyDate = new MSSQL.Field(this, "ReplyDate", "ReplyDate", SqlDbType.DateTime, false);
                ReplyContent = new MSSQL.Field(this, "ReplyContent", "ReplyContent", SqlDbType.VarChar, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Shop_Supplier : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field SupplierName;
            public MSSQL.Field Address;
            public MSSQL.Field Contact;
            public MSSQL.Field Tel;
            public MSSQL.Field Remark;
            public MSSQL.Field Isuse;
            public MSSQL.Field ShopID;

            public tbl_Shop_Supplier()
            {
                TableName = "tbl_Shop_Supplier";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                SupplierName = new MSSQL.Field(this, "SupplierName", "SupplierName", SqlDbType.VarChar, false);
                Address = new MSSQL.Field(this, "Address", "Address", SqlDbType.VarChar, false);
                Contact = new MSSQL.Field(this, "Contact", "Contact", SqlDbType.VarChar, false);
                Tel = new MSSQL.Field(this, "Tel", "Tel", SqlDbType.VarChar, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                Isuse = new MSSQL.Field(this, "Isuse", "Isuse", SqlDbType.Bit, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_SMS : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field SiteID;
            public MSSQL.Field SMSID;
            public MSSQL.Field From;
            public MSSQL.Field To;
            public MSSQL.Field DateTime;
            public MSSQL.Field Content;
            public MSSQL.Field isSend;

            public tbl_SMS()
            {
                TableName = "tbl_SMS";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                SiteID = new MSSQL.Field(this, "SiteID", "SiteID", SqlDbType.BigInt, false);
                SMSID = new MSSQL.Field(this, "SMSID", "SMSID", SqlDbType.BigInt, false);
                From = new MSSQL.Field(this, "From", "From", SqlDbType.VarChar, false);
                To = new MSSQL.Field(this, "To", "To", SqlDbType.VarChar, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Content = new MSSQL.Field(this, "Content", "Content", SqlDbType.VarChar, false);
                isSend = new MSSQL.Field(this, "isSend", "isSend", SqlDbType.Bit, false);
            }
        }

        public class tbl_Shop_RequestGoodMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field RequestGoodNo;
            public MSSQL.Field SourceShopID;
            public MSSQL.Field TargetShopID;
            public MSSQL.Field Status;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Remark;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;

            public tbl_Shop_RequestGoodMaster()
            {
                TableName = "tbl_Shop_RequestGoodMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                RequestGoodNo = new MSSQL.Field(this, "RequestGoodNo", "RequestGoodNo", SqlDbType.VarChar, false);
                SourceShopID = new MSSQL.Field(this, "SourceShopID", "SourceShopID", SqlDbType.BigInt, false);
                TargetShopID = new MSSQL.Field(this, "TargetShopID", "TargetShopID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
            }
        }

        public class tbl_Shop_ShopType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeName;

            public tbl_Shop_ShopType()
            {
                TableName = "tbl_Shop_ShopType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, false);
                TypeName = new MSSQL.Field(this, "TypeName", "TypeName", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Site_OnlineSurvey : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Title;
            public MSSQL.Field IsShow;
            public MSSQL.Field DateTime;
            public MSSQL.Field Amount;

            public tbl_Site_OnlineSurvey()
            {
                TableName = "tbl_Site_OnlineSurvey";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                Title = new MSSQL.Field(this, "Title", "Title", SqlDbType.VarChar, false);
                IsShow = new MSSQL.Field(this, "IsShow", "IsShow", SqlDbType.Bit, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_ShopStock : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field GoodID;
            public MSSQL.Field Amount;
            public MSSQL.Field upDate;
            public MSSQL.Field isOnSale;
            public MSSQL.Field isNew;
            public MSSQL.Field isHot;
            public MSSQL.Field IsCommend;
            public MSSQL.Field IsFavorable;
            public MSSQL.Field UnMarketedNum;
            public MSSQL.Field UnMarketedDate;

            public tbl_Shop_ShopStock()
            {
                TableName = "tbl_Shop_ShopStock";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
                upDate = new MSSQL.Field(this, "upDate", "upDate", SqlDbType.DateTime, false);
                isOnSale = new MSSQL.Field(this, "isOnSale", "isOnSale", SqlDbType.Bit, false);
                isNew = new MSSQL.Field(this, "isNew", "isNew", SqlDbType.Bit, false);
                isHot = new MSSQL.Field(this, "isHot", "isHot", SqlDbType.Bit, false);
                IsCommend = new MSSQL.Field(this, "IsCommend", "IsCommend", SqlDbType.Bit, false);
                IsFavorable = new MSSQL.Field(this, "IsFavorable", "IsFavorable", SqlDbType.Bit, false);
                UnMarketedNum = new MSSQL.Field(this, "UnMarketedNum", "UnMarketedNum", SqlDbType.Int, false);
                UnMarketedDate = new MSSQL.Field(this, "UnMarketedDate", "UnMarketedDate", SqlDbType.DateTime, false);
            }
        }

        public class tbl_Earning : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field PV;
            public MSSQL.Field CountA;
            public MSSQL.Field CountB;
            public MSSQL.Field MonthA;
            public MSSQL.Field MonthB;
            public MSSQL.Field DateTime;

            public tbl_Earning()
            {
                TableName = "tbl_Earning";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                CountA = new MSSQL.Field(this, "CountA", "CountA", SqlDbType.Money, false);
                CountB = new MSSQL.Field(this, "CountB", "CountB", SqlDbType.Money, false);
                MonthA = new MSSQL.Field(this, "MonthA", "MonthA", SqlDbType.Money, false);
                MonthB = new MSSQL.Field(this, "MonthB", "MonthB", SqlDbType.Money, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
            }
        }

        public class tbl_Site_HelpType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeName;
            public MSSQL.Field ParentID;
            public MSSQL.Field Sort;
            public MSSQL.Field Status;
            public MSSQL.Field Introduce;
            public MSSQL.Field ShopID;

            public tbl_Site_HelpType()
            {
                TableName = "tbl_Site_HelpType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                TypeName = new MSSQL.Field(this, "TypeName", "TypeName", SqlDbType.VarChar, false);
                ParentID = new MSSQL.Field(this, "ParentID", "ParentID", SqlDbType.Int, false);
                Sort = new MSSQL.Field(this, "Sort", "Sort", SqlDbType.NChar, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                Introduce = new MSSQL.Field(this, "Introduce", "Introduce", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Site_FatoviteGood : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field GoodID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field ShopID;

            public tbl_Site_FatoviteGood()
            {
                TableName = "tbl_Site_FatoviteGood";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Shop_SalesMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field SalesNO;
            public MSSQL.Field SalesType;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field CustomerID;
            public MSSQL.Field Status;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;
            public MSSQL.Field Remark;
            public MSSQL.Field ShopID;
            public MSSQL.Field PayType;
            public MSSQL.Field CarriageType;
            public MSSQL.Field ConsigneeName;
            public MSSQL.Field ConsigneeTel;
            public MSSQL.Field ConsigneeMobile;
            public MSSQL.Field ConsigneeEmail;
            public MSSQL.Field ConsigneeZipCode;
            public MSSQL.Field ConsigneeAdress;
            public MSSQL.Field PV;
            public MSSQL.Field IsTicket;

            public tbl_Shop_SalesMaster()
            {
                TableName = "tbl_Shop_SalesMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                SalesNO = new MSSQL.Field(this, "SalesNO", "SalesNO", SqlDbType.VarChar, false);
                SalesType = new MSSQL.Field(this, "SalesType", "SalesType", SqlDbType.TinyInt, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                PayType = new MSSQL.Field(this, "PayType", "PayType", SqlDbType.Int, false);
                CarriageType = new MSSQL.Field(this, "CarriageType", "CarriageType", SqlDbType.Int, false);
                ConsigneeName = new MSSQL.Field(this, "ConsigneeName", "ConsigneeName", SqlDbType.VarChar, false);
                ConsigneeTel = new MSSQL.Field(this, "ConsigneeTel", "ConsigneeTel", SqlDbType.VarChar, false);
                ConsigneeMobile = new MSSQL.Field(this, "ConsigneeMobile", "ConsigneeMobile", SqlDbType.VarChar, false);
                ConsigneeEmail = new MSSQL.Field(this, "ConsigneeEmail", "ConsigneeEmail", SqlDbType.VarChar, false);
                ConsigneeZipCode = new MSSQL.Field(this, "ConsigneeZipCode", "ConsigneeZipCode", SqlDbType.VarChar, false);
                ConsigneeAdress = new MSSQL.Field(this, "ConsigneeAdress", "ConsigneeAdress", SqlDbType.VarChar, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Float, false);
                IsTicket = new MSSQL.Field(this, "IsTicket", "IsTicket", SqlDbType.Bit, false);
            }
        }

        public class tbl_Shop_Brand : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field BrandName_CN;
            public MSSQL.Field BrandName_EN;
            public MSSQL.Field BrandPic;
            public MSSQL.Field Introduce;
            public MSSQL.Field Remark;
            public MSSQL.Field Isuse;
            public MSSQL.Field ShopID;

            public tbl_Shop_Brand()
            {
                TableName = "tbl_Shop_Brand";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                BrandName_CN = new MSSQL.Field(this, "BrandName_CN", "BrandName_CN", SqlDbType.VarChar, false);
                BrandName_EN = new MSSQL.Field(this, "BrandName_EN", "BrandName_EN", SqlDbType.VarChar, false);
                BrandPic = new MSSQL.Field(this, "BrandPic", "BrandPic", SqlDbType.VarChar, false);
                Introduce = new MSSQL.Field(this, "Introduce", "Introduce", SqlDbType.VarChar, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                Isuse = new MSSQL.Field(this, "Isuse", "Isuse", SqlDbType.Bit, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_CompetencesOfGroups : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field GroupID;
            public MSSQL.Field CompetenceID;
            public MSSQL.Field ShopID;

            public tbl_CompetencesOfGroups()
            {
                TableName = "tbl_CompetencesOfGroups";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                GroupID = new MSSQL.Field(this, "GroupID", "GroupID", SqlDbType.BigInt, false);
                CompetenceID = new MSSQL.Field(this, "CompetenceID", "CompetenceID", SqlDbType.SmallInt, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Site_Article : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ArticleTypeID;
            public MSSQL.Field Title;
            public MSSQL.Field Content;
            public MSSQL.Field CreateDate;
            public MSSQL.Field isShow;
            public MSSQL.Field ShopID;

            public tbl_Site_Article()
            {
                TableName = "tbl_Site_Article";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ArticleTypeID = new MSSQL.Field(this, "ArticleTypeID", "ArticleTypeID", SqlDbType.Int, false);
                Title = new MSSQL.Field(this, "Title", "Title", SqlDbType.VarChar, false);
                Content = new MSSQL.Field(this, "Content", "Content", SqlDbType.VarChar, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                isShow = new MSSQL.Field(this, "isShow", "isShow", SqlDbType.Bit, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Shop_DepotOutMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field OutNO;
            public MSSQL.Field OutType;
            public MSSQL.Field InvoiceID;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field SourceShopID;
            public MSSQL.Field TargetShopID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field Status;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Remark;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;
            public MSSQL.Field ShopID;

            public tbl_Shop_DepotOutMaster()
            {
                TableName = "tbl_Shop_DepotOutMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                OutNO = new MSSQL.Field(this, "OutNO", "OutNO", SqlDbType.VarChar, false);
                OutType = new MSSQL.Field(this, "OutType", "OutType", SqlDbType.TinyInt, false);
                InvoiceID = new MSSQL.Field(this, "InvoiceID", "InvoiceID", SqlDbType.BigInt, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                SourceShopID = new MSSQL.Field(this, "SourceShopID", "SourceShopID", SqlDbType.BigInt, false);
                TargetShopID = new MSSQL.Field(this, "TargetShopID", "TargetShopID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_CompetencesOfCustomers : MSSQL.TableBase
        {
            public MSSQL.Field CustomerID;
            public MSSQL.Field CompetenceID;
            public MSSQL.Field ShopID;

            public tbl_CompetencesOfCustomers()
            {
                TableName = "tbl_CompetencesOfCustomers";

                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                CompetenceID = new MSSQL.Field(this, "CompetenceID", "CompetenceID", SqlDbType.SmallInt, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Competences : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;
            public MSSQL.Field Code;
            public MSSQL.Field Description;

            public tbl_Competences()
            {
                TableName = "tbl_Competences";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, false);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                Code = new MSSQL.Field(this, "Code", "Code", SqlDbType.VarChar, false);
                Description = new MSSQL.Field(this, "Description", "Description", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Citys : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ProvinceID;
            public MSSQL.Field Name;

            public tbl_Citys()
            {
                TableName = "tbl_Citys";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, false);
                ProvinceID = new MSSQL.Field(this, "ProvinceID", "ProvinceID", SqlDbType.Int, false);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_CarriageType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CarriageTypeName;

            public tbl_Shop_CarriageType()
            {
                TableName = "tbl_Shop_CarriageType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CarriageTypeName = new MSSQL.Field(this, "CarriageTypeName", "CarriageTypeName", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_CarriageCompany : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;
            public MSSQL.Field CarriageTel;
            public MSSQL.Field CarriageMen;

            public tbl_Shop_CarriageCompany()
            {
                TableName = "tbl_Shop_CarriageCompany";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                CarriageTel = new MSSQL.Field(this, "CarriageTel", "CarriageTel", SqlDbType.VarChar, false);
                CarriageMen = new MSSQL.Field(this, "CarriageMen", "CarriageMen", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_DepotOutDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field OutID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_DepotOutDetail()
            {
                TableName = "tbl_Shop_DepotOutDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                OutID = new MSSQL.Field(this, "OutID", "OutID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_Good : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field Weight;

            public tbl_Shop_Good()
            {
                TableName = "tbl_Shop_Good";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                Weight = new MSSQL.Field(this, "Weight", "Weight", SqlDbType.Float, false);
            }
        }

        public class tbl_Banks : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;
            public MSSQL.Field Order;

            public tbl_Banks()
            {
                TableName = "tbl_Banks";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.SmallInt, true);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                Order = new MSSQL.Field(this, "Order", "Order", SqlDbType.SmallInt, false);
            }
        }

        public class tbl_Shop_DepotINMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field InNO;
            public MSSQL.Field InType;
            public MSSQL.Field InvoiceID;
            public MSSQL.Field SupplierID;
            public MSSQL.Field SourceShopID;
            public MSSQL.Field TargetShopID;
            public MSSQL.Field Status;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Remark;
            public MSSQL.Field ShopID;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;

            public tbl_Shop_DepotINMaster()
            {
                TableName = "tbl_Shop_DepotINMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                InNO = new MSSQL.Field(this, "InNO", "InNO", SqlDbType.VarChar, false);
                InType = new MSSQL.Field(this, "InType", "InType", SqlDbType.TinyInt, false);
                InvoiceID = new MSSQL.Field(this, "InvoiceID", "InvoiceID", SqlDbType.BigInt, false);
                SupplierID = new MSSQL.Field(this, "SupplierID", "SupplierID", SqlDbType.BigInt, false);
                SourceShopID = new MSSQL.Field(this, "SourceShopID", "SourceShopID", SqlDbType.BigInt, false);
                TargetShopID = new MSSQL.Field(this, "TargetShopID", "TargetShopID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
            }
        }

        public class tbl_Shop_BackGoodMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field BackGoodNO;
            public MSSQL.Field CustomerID;
            public MSSQL.Field TargetShopID;
            public MSSQL.Field SourceShopID;
            public MSSQL.Field Status;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Type;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;
            public MSSQL.Field ReturnSeason;
            public MSSQL.Field DeclineSeason;
            public MSSQL.Field ShopID;

            public tbl_Shop_BackGoodMaster()
            {
                TableName = "tbl_Shop_BackGoodMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                BackGoodNO = new MSSQL.Field(this, "BackGoodNO", "BackGoodNO", SqlDbType.VarChar, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                TargetShopID = new MSSQL.Field(this, "TargetShopID", "TargetShopID", SqlDbType.BigInt, false);
                SourceShopID = new MSSQL.Field(this, "SourceShopID", "SourceShopID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
                ReturnSeason = new MSSQL.Field(this, "ReturnSeason", "ReturnSeason", SqlDbType.VarChar, false);
                DeclineSeason = new MSSQL.Field(this, "DeclineSeason", "DeclineSeason", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Site_HelpExpress : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeID;
            public MSSQL.Field Value;
            public MSSQL.Field ValueBinary;
            public MSSQL.Field Status;
            public MSSQL.Field DateTime;

            public tbl_Site_HelpExpress()
            {
                TableName = "tbl_Site_HelpExpress";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                TypeID = new MSSQL.Field(this, "TypeID", "TypeID", SqlDbType.Int, false);
                Value = new MSSQL.Field(this, "Value", "Value", SqlDbType.VarChar, false);
                ValueBinary = new MSSQL.Field(this, "ValueBinary", "ValueBinary", SqlDbType.Image, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
            }
        }

        public class tbl_Shop_BackGoodDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field BackGoodID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_BackGoodDetail()
            {
                TableName = "tbl_Shop_BackGoodDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                BackGoodID = new MSSQL.Field(this, "BackGoodID", "BackGoodID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_DepotINDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field InID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;
            public MSSQL.Field ActualAmount;

            public tbl_Shop_DepotINDetail()
            {
                TableName = "tbl_Shop_DepotINDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                InID = new MSSQL.Field(this, "InID", "InID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
                ActualAmount = new MSSQL.Field(this, "ActualAmount", "ActualAmount", SqlDbType.Int, false);
            }
        }

        public class tbl_SystemLog : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field OperatorDate;
            public MSSQL.Field OperatorID;
            public MSSQL.Field ModelName;
            public MSSQL.Field ActionName;
            public MSSQL.Field DescriptionNo;
            public MSSQL.Field IP;
            public MSSQL.Field Memo;
            public MSSQL.Field Type;

            public tbl_SystemLog()
            {
                TableName = "tbl_SystemLog";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                OperatorDate = new MSSQL.Field(this, "OperatorDate", "OperatorDate", SqlDbType.DateTime, false);
                OperatorID = new MSSQL.Field(this, "OperatorID", "OperatorID", SqlDbType.VarChar, false);
                ModelName = new MSSQL.Field(this, "ModelName", "ModelName", SqlDbType.VarChar, false);
                ActionName = new MSSQL.Field(this, "ActionName", "ActionName", SqlDbType.VarChar, false);
                DescriptionNo = new MSSQL.Field(this, "DescriptionNo", "DescriptionNo", SqlDbType.VarChar, false);
                IP = new MSSQL.Field(this, "IP", "IP", SqlDbType.VarChar, false);
                Memo = new MSSQL.Field(this, "Memo", "Memo", SqlDbType.VarChar, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_ShipmentMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShipmentNo;
            public MSSQL.Field InvoiceID;
            public MSSQL.Field CustomerName;
            public MSSQL.Field Address;
            public MSSQL.Field Telephone;
            public MSSQL.Field Mobile;
            public MSSQL.Field Email;
            public MSSQL.Field PostCode;
            public MSSQL.Field CarriageCompany;
            public MSSQL.Field CarriageNo;
            public MSSQL.Field CarriageTel;
            public MSSQL.Field CarriageMoney;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field CreateTime;
            public MSSQL.Field ShipmentDate;
            public MSSQL.Field ShipmentOperatorID;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;
            public MSSQL.Field Status;
            public MSSQL.Field Remark;

            public tbl_Shop_ShipmentMaster()
            {
                TableName = "tbl_Shop_ShipmentMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShipmentNo = new MSSQL.Field(this, "ShipmentNo", "ShipmentNo", SqlDbType.VarChar, false);
                InvoiceID = new MSSQL.Field(this, "InvoiceID", "InvoiceID", SqlDbType.BigInt, false);
                CustomerName = new MSSQL.Field(this, "CustomerName", "CustomerName", SqlDbType.VarChar, false);
                Address = new MSSQL.Field(this, "Address", "Address", SqlDbType.VarChar, false);
                Telephone = new MSSQL.Field(this, "Telephone", "Telephone", SqlDbType.VarChar, false);
                Mobile = new MSSQL.Field(this, "Mobile", "Mobile", SqlDbType.VarChar, false);
                Email = new MSSQL.Field(this, "Email", "Email", SqlDbType.VarChar, false);
                PostCode = new MSSQL.Field(this, "PostCode", "PostCode", SqlDbType.VarChar, false);
                CarriageCompany = new MSSQL.Field(this, "CarriageCompany", "CarriageCompany", SqlDbType.VarChar, false);
                CarriageNo = new MSSQL.Field(this, "CarriageNo", "CarriageNo", SqlDbType.VarChar, false);
                CarriageTel = new MSSQL.Field(this, "CarriageTel", "CarriageTel", SqlDbType.VarChar, false);
                CarriageMoney = new MSSQL.Field(this, "CarriageMoney", "CarriageMoney", SqlDbType.VarChar, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                CreateTime = new MSSQL.Field(this, "CreateTime", "CreateTime", SqlDbType.DateTime, false);
                ShipmentDate = new MSSQL.Field(this, "ShipmentDate", "ShipmentDate", SqlDbType.DateTime, false);
                ShipmentOperatorID = new MSSQL.Field(this, "ShipmentOperatorID", "ShipmentOperatorID", SqlDbType.BigInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_ShipmentDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShipmentID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_ShipmentDetail()
            {
                TableName = "tbl_Shop_ShipmentDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShipmentID = new MSSQL.Field(this, "ShipmentID", "ShipmentID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_Site_ArticleType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeName;

            public tbl_Site_ArticleType()
            {
                TableName = "tbl_Site_ArticleType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, false);
                TypeName = new MSSQL.Field(this, "TypeName", "TypeName", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Customer : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerNo;
            public MSSQL.Field CustomerName;
            public MSSQL.Field CustomerTypeID;
            public MSSQL.Field Bills;
            public MSSQL.Field Password1;
            public MSSQL.Field Password2;
            public MSSQL.Field Tel;
            public MSSQL.Field Mobile;
            public MSSQL.Field QQ;
            public MSSQL.Field Email;
            public MSSQL.Field PostCode;
            public MSSQL.Field CityID;
            public MSSQL.Field Address;
            public MSSQL.Field Fax;
            public MSSQL.Field Other;
            public MSSQL.Field Sex;
            public MSSQL.Field Birthday;
            public MSSQL.Field CertTypeID;
            public MSSQL.Field CertNo;
            public MSSQL.Field BankTypeID;
            public MSSQL.Field BankNameDetail;
            public MSSQL.Field BankCardNumber;
            public MSSQL.Field BankCustName;
            public MSSQL.Field AlipayNo;
            public MSSQL.Field DeptID;
            public MSSQL.Field RegisterOperID;
            public MSSQL.Field RegisterDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Status;
            public MSSQL.Field Remark;
            public MSSQL.Field ShopID;
            public MSSQL.Field RegisterShopID;
            public MSSQL.Field SurrogateID;
            public MSSQL.Field CommendID;
            public MSSQL.Field ParentID;
            public MSSQL.Field LR;
            public MSSQL.Field isLock;
            public MSSQL.Field isActivation;
            public MSSQL.Field IsSurrogate;
            public MSSQL.Field Balance;
            public MSSQL.Field Freeze;
            public MSSQL.Field Tax;
            public MSSQL.Field FundManage;
            public MSSQL.Field FundManageDistill;
            public MSSQL.Field FundManageDistillUserSelf;
            public MSSQL.Field Earning;
            public MSSQL.Field EarningBalance;
            public MSSQL.Field Earning2;
            public MSSQL.Field EarningBalance2;
            public MSSQL.Field Earning3;
            public MSSQL.Field EarningBalance3;
            public MSSQL.Field PV;
            public MSSQL.Field BV;
            public MSSQL.Field UpVipDate;
            public MSSQL.Field LastLoginTime;
            public MSSQL.Field LastLoginIP;
            public MSSQL.Field LoginNum;

            public tbl_Customer()
            {
                TableName = "tbl_Customer";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerNo = new MSSQL.Field(this, "CustomerNo", "CustomerNo", SqlDbType.VarChar, false);
                CustomerName = new MSSQL.Field(this, "CustomerName", "CustomerName", SqlDbType.VarChar, false);
                CustomerTypeID = new MSSQL.Field(this, "CustomerTypeID", "CustomerTypeID", SqlDbType.Int, false);
                Bills = new MSSQL.Field(this, "Bills", "Bills", SqlDbType.Int, false);
                Password1 = new MSSQL.Field(this, "Password1", "Password1", SqlDbType.VarChar, false);
                Password2 = new MSSQL.Field(this, "Password2", "Password2", SqlDbType.VarChar, false);
                Tel = new MSSQL.Field(this, "Tel", "Tel", SqlDbType.VarChar, false);
                Mobile = new MSSQL.Field(this, "Mobile", "Mobile", SqlDbType.VarChar, false);
                QQ = new MSSQL.Field(this, "QQ", "QQ", SqlDbType.VarChar, false);
                Email = new MSSQL.Field(this, "Email", "Email", SqlDbType.VarChar, false);
                PostCode = new MSSQL.Field(this, "PostCode", "PostCode", SqlDbType.VarChar, false);
                CityID = new MSSQL.Field(this, "CityID", "CityID", SqlDbType.BigInt, false);
                Address = new MSSQL.Field(this, "Address", "Address", SqlDbType.VarChar, false);
                Fax = new MSSQL.Field(this, "Fax", "Fax", SqlDbType.VarChar, false);
                Other = new MSSQL.Field(this, "Other", "Other", SqlDbType.VarChar, false);
                Sex = new MSSQL.Field(this, "Sex", "Sex", SqlDbType.VarChar, false);
                Birthday = new MSSQL.Field(this, "Birthday", "Birthday", SqlDbType.DateTime, false);
                CertTypeID = new MSSQL.Field(this, "CertTypeID", "CertTypeID", SqlDbType.Int, false);
                CertNo = new MSSQL.Field(this, "CertNo", "CertNo", SqlDbType.VarChar, false);
                BankTypeID = new MSSQL.Field(this, "BankTypeID", "BankTypeID", SqlDbType.Int, false);
                BankNameDetail = new MSSQL.Field(this, "BankNameDetail", "BankNameDetail", SqlDbType.VarChar, false);
                BankCardNumber = new MSSQL.Field(this, "BankCardNumber", "BankCardNumber", SqlDbType.VarChar, false);
                BankCustName = new MSSQL.Field(this, "BankCustName", "BankCustName", SqlDbType.VarChar, false);
                AlipayNo = new MSSQL.Field(this, "AlipayNo", "AlipayNo", SqlDbType.VarChar, false);
                DeptID = new MSSQL.Field(this, "DeptID", "DeptID", SqlDbType.Int, false);
                RegisterOperID = new MSSQL.Field(this, "RegisterOperID", "RegisterOperID", SqlDbType.BigInt, false);
                RegisterDate = new MSSQL.Field(this, "RegisterDate", "RegisterDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.Int, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                RegisterShopID = new MSSQL.Field(this, "RegisterShopID", "RegisterShopID", SqlDbType.BigInt, false);
                SurrogateID = new MSSQL.Field(this, "SurrogateID", "SurrogateID", SqlDbType.BigInt, false);
                CommendID = new MSSQL.Field(this, "CommendID", "CommendID", SqlDbType.BigInt, false);
                ParentID = new MSSQL.Field(this, "ParentID", "ParentID", SqlDbType.BigInt, false);
                LR = new MSSQL.Field(this, "LR", "LR", SqlDbType.Int, false);
                isLock = new MSSQL.Field(this, "isLock", "isLock", SqlDbType.Bit, false);
                isActivation = new MSSQL.Field(this, "isActivation", "isActivation", SqlDbType.Bit, false);
                IsSurrogate = new MSSQL.Field(this, "IsSurrogate", "IsSurrogate", SqlDbType.Bit, false);
                Balance = new MSSQL.Field(this, "Balance", "Balance", SqlDbType.Money, false);
                Freeze = new MSSQL.Field(this, "Freeze", "Freeze", SqlDbType.Money, false);
                Tax = new MSSQL.Field(this, "Tax", "Tax", SqlDbType.Money, false);
                FundManage = new MSSQL.Field(this, "FundManage", "FundManage", SqlDbType.Money, false);
                FundManageDistill = new MSSQL.Field(this, "FundManageDistill", "FundManageDistill", SqlDbType.Int, false);
                FundManageDistillUserSelf = new MSSQL.Field(this, "FundManageDistillUserSelf", "FundManageDistillUserSelf", SqlDbType.Int, false);
                Earning = new MSSQL.Field(this, "Earning", "Earning", SqlDbType.Money, false);
                EarningBalance = new MSSQL.Field(this, "EarningBalance", "EarningBalance", SqlDbType.Money, false);
                Earning2 = new MSSQL.Field(this, "Earning2", "Earning2", SqlDbType.Money, false);
                EarningBalance2 = new MSSQL.Field(this, "EarningBalance2", "EarningBalance2", SqlDbType.Money, false);
                Earning3 = new MSSQL.Field(this, "Earning3", "Earning3", SqlDbType.Money, false);
                EarningBalance3 = new MSSQL.Field(this, "EarningBalance3", "EarningBalance3", SqlDbType.Money, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                BV = new MSSQL.Field(this, "BV", "BV", SqlDbType.Money, false);
                UpVipDate = new MSSQL.Field(this, "UpVipDate", "UpVipDate", SqlDbType.DateTime, false);
                LastLoginTime = new MSSQL.Field(this, "LastLoginTime", "LastLoginTime", SqlDbType.DateTime, false);
                LastLoginIP = new MSSQL.Field(this, "LastLoginIP", "LastLoginIP", SqlDbType.VarChar, false);
                LoginNum = new MSSQL.Field(this, "LoginNum", "LoginNum", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_AllocateMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field AllocateNO;
            public MSSQL.Field SourceShopID;
            public MSSQL.Field TargetShopID;
            public MSSQL.Field Status;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Remark;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field InvoiceID;
            public MSSQL.Field AllocateType;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;

            public tbl_Shop_AllocateMaster()
            {
                TableName = "tbl_Shop_AllocateMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                AllocateNO = new MSSQL.Field(this, "AllocateNO", "AllocateNO", SqlDbType.VarChar, false);
                SourceShopID = new MSSQL.Field(this, "SourceShopID", "SourceShopID", SqlDbType.BigInt, false);
                TargetShopID = new MSSQL.Field(this, "TargetShopID", "TargetShopID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                InvoiceID = new MSSQL.Field(this, "InvoiceID", "InvoiceID", SqlDbType.BigInt, false);
                AllocateType = new MSSQL.Field(this, "AllocateType", "AllocateType", SqlDbType.TinyInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
            }
        }

        public class tbl_CustomerSubsOfDay : MSSQL.TableBase
        {
            public MSSQL.Field Year;
            public MSSQL.Field Month;
            public MSSQL.Field Day;
            public MSSQL.Field CustomerID;
            public MSSQL.Field L;
            public MSSQL.Field R;
            public MSSQL.Field LDistilled;
            public MSSQL.Field RDistilled;

            public tbl_CustomerSubsOfDay()
            {
                TableName = "tbl_CustomerSubsOfDay";

                Year = new MSSQL.Field(this, "Year", "Year", SqlDbType.Int, false);
                Month = new MSSQL.Field(this, "Month", "Month", SqlDbType.Int, false);
                Day = new MSSQL.Field(this, "Day", "Day", SqlDbType.Int, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                L = new MSSQL.Field(this, "L", "L", SqlDbType.BigInt, false);
                R = new MSSQL.Field(this, "R", "R", SqlDbType.BigInt, false);
                LDistilled = new MSSQL.Field(this, "LDistilled", "LDistilled", SqlDbType.BigInt, false);
                RDistilled = new MSSQL.Field(this, "RDistilled", "RDistilled", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Shop_AllocateDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field AllocateID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_AllocateDetail()
            {
                TableName = "tbl_Shop_AllocateDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                AllocateID = new MSSQL.Field(this, "AllocateID", "AllocateID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_CustomerPayNumberList : MSSQL.TableBase
        {
            public MSSQL.Field PayNumber;
            public MSSQL.Field Money;

            public tbl_CustomerPayNumberList()
            {
                TableName = "tbl_CustomerPayNumberList";

                PayNumber = new MSSQL.Field(this, "PayNumber", "PayNumber", SqlDbType.BigInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Money, false);
            }
        }

        public class tbl_CustomerType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeName;
            public MSSQL.Field PlanID;
            public MSSQL.Field IsAward;

            public tbl_CustomerType()
            {
                TableName = "tbl_CustomerType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.TinyInt, true);
                TypeName = new MSSQL.Field(this, "TypeName", "TypeName", SqlDbType.VarChar, false);
                PlanID = new MSSQL.Field(this, "PlanID", "PlanID", SqlDbType.NChar, false);
                IsAward = new MSSQL.Field(this, "IsAward", "IsAward", SqlDbType.Bit, false);
            }
        }

        public class tbl_CustomerPayDetails : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field PayType;
            public MSSQL.Field Money;
            public MSSQL.Field FormalitiesFees;
            public MSSQL.Field RealMoney;
            public MSSQL.Field Result;
            public MSSQL.Field RelatedOrderType;
            public MSSQL.Field RelatedOrderID;

            public tbl_CustomerPayDetails()
            {
                TableName = "tbl_CustomerPayDetails";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                PayType = new MSSQL.Field(this, "PayType", "PayType", SqlDbType.VarChar, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Money, false);
                FormalitiesFees = new MSSQL.Field(this, "FormalitiesFees", "FormalitiesFees", SqlDbType.Money, false);
                RealMoney = new MSSQL.Field(this, "RealMoney", "RealMoney", SqlDbType.Money, false);
                Result = new MSSQL.Field(this, "Result", "Result", SqlDbType.SmallInt, false);
                RelatedOrderType = new MSSQL.Field(this, "RelatedOrderType", "RelatedOrderType", SqlDbType.Int, false);
                RelatedOrderID = new MSSQL.Field(this, "RelatedOrderID", "RelatedOrderID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Department : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;
            public MSSQL.Field Remark;
            public MSSQL.Field ShopID;
            public MSSQL.Field IsUse;
            public MSSQL.Field ParentID;

            public tbl_Department()
            {
                TableName = "tbl_Department";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                IsUse = new MSSQL.Field(this, "IsUse", "IsUse", SqlDbType.Bit, false);
                ParentID = new MSSQL.Field(this, "ParentID", "ParentID", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_SalesDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field SalesID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_SalesDetail()
            {
                TableName = "tbl_Shop_SalesDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                SalesID = new MSSQL.Field(this, "SalesID", "SalesID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_CustomerInGroups : MSSQL.TableBase
        {
            public MSSQL.Field CustomerID;
            public MSSQL.Field GroupID;
            public MSSQL.Field ShopID;

            public tbl_CustomerInGroups()
            {
                TableName = "tbl_CustomerInGroups";

                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                GroupID = new MSSQL.Field(this, "GroupID", "GroupID", SqlDbType.Int, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Shop_RequestGoodDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field RequestGoodID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field SiteID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_RequestGoodDetail()
            {
                TableName = "tbl_Shop_RequestGoodDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                RequestGoodID = new MSSQL.Field(this, "RequestGoodID", "RequestGoodID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                SiteID = new MSSQL.Field(this, "SiteID", "SiteID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_CustomerGroups : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;
            public MSSQL.Field Description;
            public MSSQL.Field ShopID;

            public tbl_CustomerGroups()
            {
                TableName = "tbl_CustomerGroups";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                Description = new MSSQL.Field(this, "Description", "Description", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_CustomerDistills : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field Money;
            public MSSQL.Field FormalitiesFees;
            public MSSQL.Field Memo;
            public MSSQL.Field Result;
            public MSSQL.Field HandleDateTime;
            public MSSQL.Field BankName;
            public MSSQL.Field BankCardNumber;
            public MSSQL.Field OperatorID;
            public MSSQL.Field isPersonal;
            public MSSQL.Field PaymentType;
            public MSSQL.Field PaymentFilesID;
            public MSSQL.Field Memo1;
            public MSSQL.Field Type;

            public tbl_CustomerDistills()
            {
                TableName = "tbl_CustomerDistills";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Money, false);
                FormalitiesFees = new MSSQL.Field(this, "FormalitiesFees", "FormalitiesFees", SqlDbType.Money, false);
                Memo = new MSSQL.Field(this, "Memo", "Memo", SqlDbType.VarChar, false);
                Result = new MSSQL.Field(this, "Result", "Result", SqlDbType.SmallInt, false);
                HandleDateTime = new MSSQL.Field(this, "HandleDateTime", "HandleDateTime", SqlDbType.DateTime, false);
                BankName = new MSSQL.Field(this, "BankName", "BankName", SqlDbType.VarChar, false);
                BankCardNumber = new MSSQL.Field(this, "BankCardNumber", "BankCardNumber", SqlDbType.VarChar, false);
                OperatorID = new MSSQL.Field(this, "OperatorID", "OperatorID", SqlDbType.BigInt, false);
                isPersonal = new MSSQL.Field(this, "isPersonal", "isPersonal", SqlDbType.Bit, false);
                PaymentType = new MSSQL.Field(this, "PaymentType", "PaymentType", SqlDbType.Int, false);
                PaymentFilesID = new MSSQL.Field(this, "PaymentFilesID", "PaymentFilesID", SqlDbType.BigInt, false);
                Memo1 = new MSSQL.Field(this, "Memo1", "Memo1", SqlDbType.VarChar, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
            }
        }

        public class tbl_Provinces : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;

            public tbl_Provinces()
            {
                TableName = "tbl_Provinces";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, false);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_PrintNum : MSSQL.TableBase
        {
            public MSSQL.Field OrderID;
            public MSSQL.Field Type;
            public MSSQL.Field Num;

            public tbl_Shop_PrintNum()
            {
                TableName = "tbl_Shop_PrintNum";

                OrderID = new MSSQL.Field(this, "OrderID", "OrderID", SqlDbType.BigInt, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
                Num = new MSSQL.Field(this, "Num", "Num", SqlDbType.Int, false);
            }
        }

        public class tbl_CustomerPlanDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field PlanID;
            public MSSQL.Field GoodID;
            public MSSQL.Field Amount;
            public MSSQL.Field Price;

            public tbl_CustomerPlanDetail()
            {
                TableName = "tbl_CustomerPlanDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                PlanID = new MSSQL.Field(this, "PlanID", "PlanID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
                Price = new MSSQL.Field(this, "Price", "Price", SqlDbType.Money, false);
            }
        }

        public class tbl_CustomerPlan : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Name;
            public MSSQL.Field Price;
            public MSSQL.Field ImageURL;
            public MSSQL.Field Remark;
            public MSSQL.Field IsUse;

            public tbl_CustomerPlan()
            {
                TableName = "tbl_CustomerPlan";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                Price = new MSSQL.Field(this, "Price", "Price", SqlDbType.Money, false);
                ImageURL = new MSSQL.Field(this, "ImageURL", "ImageURL", SqlDbType.VarChar, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                IsUse = new MSSQL.Field(this, "IsUse", "IsUse", SqlDbType.Bit, false);
            }
        }

        public class tbl_Earning7 : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field PV;
            public MSSQL.Field Percent;
            public MSSQL.Field Bouns;
            public MSSQL.Field IsDistill;

            public tbl_Earning7()
            {
                TableName = "tbl_Earning7";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                Percent = new MSSQL.Field(this, "Percent", "Percent", SqlDbType.Float, false);
                Bouns = new MSSQL.Field(this, "Bouns", "Bouns", SqlDbType.Money, false);
                IsDistill = new MSSQL.Field(this, "IsDistill", "IsDistill", SqlDbType.Bit, false);
            }
        }

        public class tbl_PaymentFiles : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field FileName;
            public MSSQL.Field DateTime;
            public MSSQL.Field Result;
            public MSSQL.Field OperatorID;
            public MSSQL.Field Type;

            public tbl_PaymentFiles()
            {
                TableName = "tbl_PaymentFiles";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                FileName = new MSSQL.Field(this, "FileName", "FileName", SqlDbType.VarChar, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Result = new MSSQL.Field(this, "Result", "Result", SqlDbType.Int, false);
                OperatorID = new MSSQL.Field(this, "OperatorID", "OperatorID", SqlDbType.BigInt, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_OrderLog : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field OrderNo;
            public MSSQL.Field OrderType;
            public MSSQL.Field Action;
            public MSSQL.Field CustomerID;
            public MSSQL.Field OperatorTime;
            public MSSQL.Field Remark;

            public tbl_Shop_OrderLog()
            {
                TableName = "tbl_Shop_OrderLog";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                OrderNo = new MSSQL.Field(this, "OrderNo", "OrderNo", SqlDbType.VarChar, false);
                OrderType = new MSSQL.Field(this, "OrderType", "OrderType", SqlDbType.VarChar, false);
                Action = new MSSQL.Field(this, "Action", "Action", SqlDbType.VarChar, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                OperatorTime = new MSSQL.Field(this, "OperatorTime", "OperatorTime", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
            }
        }

        public class tbl_CustomerDetails : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field OperatorType;
            public MSSQL.Field Money;
            public MSSQL.Field RelatedCustomerID;
            public MSSQL.Field OperatorID;
            public MSSQL.Field Memo;
            public MSSQL.Field PayNumber;
            public MSSQL.Field PayBank;
            public MSSQL.Field FormalitiesFees;
            public MSSQL.Field IsDistill;

            public tbl_CustomerDetails()
            {
                TableName = "tbl_CustomerDetails";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                OperatorType = new MSSQL.Field(this, "OperatorType", "OperatorType", SqlDbType.SmallInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Money, false);
                RelatedCustomerID = new MSSQL.Field(this, "RelatedCustomerID", "RelatedCustomerID", SqlDbType.BigInt, false);
                OperatorID = new MSSQL.Field(this, "OperatorID", "OperatorID", SqlDbType.BigInt, false);
                Memo = new MSSQL.Field(this, "Memo", "Memo", SqlDbType.VarChar, false);
                PayNumber = new MSSQL.Field(this, "PayNumber", "PayNumber", SqlDbType.VarChar, false);
                PayBank = new MSSQL.Field(this, "PayBank", "PayBank", SqlDbType.VarChar, false);
                FormalitiesFees = new MSSQL.Field(this, "FormalitiesFees", "FormalitiesFees", SqlDbType.Money, false);
                IsDistill = new MSSQL.Field(this, "IsDistill", "IsDistill", SqlDbType.Bit, false);
            }
        }

        public class tbl_Options : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field Group;
            public MSSQL.Field Name;
            public MSSQL.Field Key;
            public MSSQL.Field Value;
            public MSSQL.Field ValueBinary;
            public MSSQL.Field Description;
            public MSSQL.Field isCanEdit;

            public tbl_Options()
            {
                TableName = "tbl_Options";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.SmallInt, false);
                Group = new MSSQL.Field(this, "Group", "Group", SqlDbType.VarChar, false);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
                Key = new MSSQL.Field(this, "Key", "Key", SqlDbType.VarChar, false);
                Value = new MSSQL.Field(this, "Value", "Value", SqlDbType.VarChar, false);
                ValueBinary = new MSSQL.Field(this, "ValueBinary", "ValueBinary", SqlDbType.Image, false);
                Description = new MSSQL.Field(this, "Description", "Description", SqlDbType.VarChar, false);
                isCanEdit = new MSSQL.Field(this, "isCanEdit", "isCanEdit", SqlDbType.Bit, false);
            }
        }

        public class tbl_Earning6 : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field PV;
            public MSSQL.Field Percent;
            public MSSQL.Field Bouns;
            public MSSQL.Field IsDistill;

            public tbl_Earning6()
            {
                TableName = "tbl_Earning6";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                Percent = new MSSQL.Field(this, "Percent", "Percent", SqlDbType.Float, false);
                Bouns = new MSSQL.Field(this, "Bouns", "Bouns", SqlDbType.Money, false);
                IsDistill = new MSSQL.Field(this, "IsDistill", "IsDistill", SqlDbType.Bit, false);
            }
        }

        public class tbl_MessageBoardCopy : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field ToCustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field Title;
            public MSSQL.Field Content;
            public MSSQL.Field ReplyDateTime;
            public MSSQL.Field Reply;
            public MSSQL.Field IPAddress;

            public tbl_MessageBoardCopy()
            {
                TableName = "tbl_MessageBoardCopy";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                ToCustomerID = new MSSQL.Field(this, "ToCustomerID", "ToCustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Title = new MSSQL.Field(this, "Title", "Title", SqlDbType.VarChar, false);
                Content = new MSSQL.Field(this, "Content", "Content", SqlDbType.Image, false);
                ReplyDateTime = new MSSQL.Field(this, "ReplyDateTime", "ReplyDateTime", SqlDbType.DateTime, false);
                Reply = new MSSQL.Field(this, "Reply", "Reply", SqlDbType.Image, false);
                IPAddress = new MSSQL.Field(this, "IPAddress", "IPAddress", SqlDbType.VarChar, false);
            }
        }

        public class tbl_CustomerBumpedDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field HasBumped;

            public tbl_CustomerBumpedDetail()
            {
                TableName = "tbl_CustomerBumpedDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                HasBumped = new MSSQL.Field(this, "HasBumped", "HasBumped", SqlDbType.Int, false);
            }
        }

        public class tbl_Earning5 : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field PV;
            public MSSQL.Field Percent;
            public MSSQL.Field Bouns;
            public MSSQL.Field IsDistill;

            public tbl_Earning5()
            {
                TableName = "tbl_Earning5";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                Percent = new MSSQL.Field(this, "Percent", "Percent", SqlDbType.Float, false);
                Bouns = new MSSQL.Field(this, "Bouns", "Bouns", SqlDbType.Money, false);
                IsDistill = new MSSQL.Field(this, "IsDistill", "IsDistill", SqlDbType.Bit, false);
            }
        }

        public class tbl_MessageBoard : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field ToCustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field Title;
            public MSSQL.Field Content;
            public MSSQL.Field ReplyDateTime;
            public MSSQL.Field Reply;
            public MSSQL.Field IPAddress;

            public tbl_MessageBoard()
            {
                TableName = "tbl_MessageBoard";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                ToCustomerID = new MSSQL.Field(this, "ToCustomerID", "ToCustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Title = new MSSQL.Field(this, "Title", "Title", SqlDbType.VarChar, false);
                Content = new MSSQL.Field(this, "Content", "Content", SqlDbType.Image, false);
                ReplyDateTime = new MSSQL.Field(this, "ReplyDateTime", "ReplyDateTime", SqlDbType.DateTime, false);
                Reply = new MSSQL.Field(this, "Reply", "Reply", SqlDbType.Image, false);
                IPAddress = new MSSQL.Field(this, "IPAddress", "IPAddress", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Site_TemplatesFile : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TemplateID;
            public MSSQL.Field Directory;
            public MSSQL.Field FileName;
            public MSSQL.Field FileType;
            public MSSQL.Field Links;
            public MSSQL.Field Remark;

            public tbl_Site_TemplatesFile()
            {
                TableName = "tbl_Site_TemplatesFile";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                TemplateID = new MSSQL.Field(this, "TemplateID", "TemplateID", SqlDbType.Int, false);
                Directory = new MSSQL.Field(this, "Directory", "Directory", SqlDbType.VarChar, false);
                FileName = new MSSQL.Field(this, "FileName", "FileName", SqlDbType.VarChar, false);
                FileType = new MSSQL.Field(this, "FileType", "FileType", SqlDbType.VarChar, false);
                Links = new MSSQL.Field(this, "Links", "Links", SqlDbType.VarChar, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Earning4 : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field PV;
            public MSSQL.Field Percent;
            public MSSQL.Field Bouns;
            public MSSQL.Field IsDistill;

            public tbl_Earning4()
            {
                TableName = "tbl_Earning4";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                Percent = new MSSQL.Field(this, "Percent", "Percent", SqlDbType.Float, false);
                Bouns = new MSSQL.Field(this, "Bouns", "Bouns", SqlDbType.Money, false);
                IsDistill = new MSSQL.Field(this, "IsDistill", "IsDistill", SqlDbType.Bit, false);
            }
        }

        public class tbl_Shop_GoodPic : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field Description;
            public MSSQL.Field IsShow;

            public tbl_Shop_GoodPic()
            {
                TableName = "tbl_Shop_GoodPic";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                Description = new MSSQL.Field(this, "Description", "Description", SqlDbType.VarChar, false);
                IsShow = new MSSQL.Field(this, "IsShow", "IsShow", SqlDbType.Bit, false);
            }
        }

        public class tbl_Site_CarriageType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeName;
            public MSSQL.Field IsUse;
            public MSSQL.Field Money;

            public tbl_Site_CarriageType()
            {
                TableName = "tbl_Site_CarriageType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                TypeName = new MSSQL.Field(this, "TypeName", "TypeName", SqlDbType.VarChar, false);
                IsUse = new MSSQL.Field(this, "IsUse", "IsUse", SqlDbType.Bit, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Money, false);
            }
        }

        public class tbl_Shop_LossDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field LossID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field ShopID;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;

            public tbl_Shop_LossDetail()
            {
                TableName = "tbl_Shop_LossDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                LossID = new MSSQL.Field(this, "LossID", "LossID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
            }
        }

        public class tbl_Site_ConsigneeAddress : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field UserID;
            public MSSQL.Field ConsigneeName;
            public MSSQL.Field ConsigneeAddress;
            public MSSQL.Field PostCode;
            public MSSQL.Field Tel;
            public MSSQL.Field Mobile;
            public MSSQL.Field Email;

            public tbl_Site_ConsigneeAddress()
            {
                TableName = "tbl_Site_ConsigneeAddress";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                UserID = new MSSQL.Field(this, "UserID", "UserID", SqlDbType.BigInt, false);
                ConsigneeName = new MSSQL.Field(this, "ConsigneeName", "ConsigneeName", SqlDbType.VarChar, false);
                ConsigneeAddress = new MSSQL.Field(this, "ConsigneeAddress", "ConsigneeAddress", SqlDbType.VarChar, false);
                PostCode = new MSSQL.Field(this, "PostCode", "PostCode", SqlDbType.VarChar, false);
                Tel = new MSSQL.Field(this, "Tel", "Tel", SqlDbType.VarChar, false);
                Mobile = new MSSQL.Field(this, "Mobile", "Mobile", SqlDbType.VarChar, false);
                Email = new MSSQL.Field(this, "Email", "Email", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Site_PayType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field PayTypeName;
            public MSSQL.Field Sort;

            public tbl_Site_PayType()
            {
                TableName = "tbl_Site_PayType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                PayTypeName = new MSSQL.Field(this, "PayTypeName", "PayTypeName", SqlDbType.VarChar, false);
                Sort = new MSSQL.Field(this, "Sort", "Sort", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_InventoryMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field InventoryNO;
            public MSSQL.Field InventoryType;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field Status;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Remark;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;
            public MSSQL.Field ShopID;

            public tbl_Shop_InventoryMaster()
            {
                TableName = "tbl_Shop_InventoryMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                InventoryNO = new MSSQL.Field(this, "InventoryNO", "InventoryNO", SqlDbType.VarChar, false);
                InventoryType = new MSSQL.Field(this, "InventoryType", "InventoryType", SqlDbType.TinyInt, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_Shop : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ParentID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field ShopTypeID;
            public MSSQL.Field ShopNo;
            public MSSQL.Field ShopName;
            public MSSQL.Field Tel;
            public MSSQL.Field Mobile;
            public MSSQL.Field QQ;
            public MSSQL.Field Email;
            public MSSQL.Field PostCode;
            public MSSQL.Field CityID;
            public MSSQL.Field Address;
            public MSSQL.Field Fax;
            public MSSQL.Field Other;
            public MSSQL.Field BankName;
            public MSSQL.Field BankNameDetail;
            public MSSQL.Field BankCustName;
            public MSSQL.Field BankCardNo;
            public MSSQL.Field RegisterOperID;
            public MSSQL.Field RegisterDate;
            public MSSQL.Field VerfyOperatorID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Status;
            public MSSQL.Field Remark;
            public MSSQL.Field SiteTitle;
            public MSSQL.Field SiteURL;
            public MSSQL.Field SiteStatus;
            public MSSQL.Field SiteQQ;
            public MSSQL.Field SiteTelephone;
            public MSSQL.Field SiteCnzz;
            public MSSQL.Field SiteScript;
            public MSSQL.Field SiteService;
            public MSSQL.Field QQ1;
            public MSSQL.Field QQ2;
            public MSSQL.Field CopyRightInfo;
            public MSSQL.Field ICPCert;
            public MSSQL.Field PV;
            public MSSQL.Field BV;
            public MSSQL.Field EnterpriseWebSite;
            public MSSQL.Field EnterpriseWebStatus;
            public MSSQL.Field Opt_isWriteLog;
            public MSSQL.Field Opt_isUseCheckCode;
            public MSSQL.Field Opt_CheckCodeCharset;
            public MSSQL.Field Opt_MemberSharing_Alipay_Status_ON;
            public MSSQL.Field Opt_MemberSharing_Alipay_Gateway;
            public MSSQL.Field Opt_MemberSharing_Alipay_UserNumber;
            public MSSQL.Field Opt_MemberSharing_Alipay_UserPassword;
            public MSSQL.Field Opt_MemberSharing_Alipay_MD5;
            public MSSQL.Field Opt_OnlinePay_Alipay_Status_ON;
            public MSSQL.Field Opt_OnlinePay_Alipay_UserName;
            public MSSQL.Field Opt_OnlinePay_Alipay_UserNumber;
            public MSSQL.Field Opt_OnlinePay_Alipay_MD5Key;
            public MSSQL.Field Opt_OnlinePay_Alipay_PayFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePayOut_Alipay_MD5Key;
            public MSSQL.Field Opt_OnlinePayOut_Alipay_DistillFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePay_99Bill_Status_ON;
            public MSSQL.Field Opt_OnlinePay_99Bill_UserName;
            public MSSQL.Field Opt_OnlinePay_99Bill_UserNumber;
            public MSSQL.Field Opt_OnlinePay_99Bill_MD5Key;
            public MSSQL.Field Opt_OnlinePay_99Bill_PayFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePayOut_99Bill_MD5Key;
            public MSSQL.Field Opt_OnlinePayOut_99Bill_DistillFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePay_Tenpay_Status_ON;
            public MSSQL.Field Opt_OnlinePay_Tenpay_UserName;
            public MSSQL.Field Opt_OnlinePay_Tenpay_UserNumber;
            public MSSQL.Field Opt_OnlinePay_Tenpay_MD5Key;
            public MSSQL.Field Opt_OnlinePay_Tenpay_PayFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePayOut_Tenpay_MD5Key;
            public MSSQL.Field Opt_OnlinePayOut_Tenpay_DistillFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePay_CBPayMent_Status_ON;
            public MSSQL.Field Opt_OnlinePay_CBPayMent_UserName;
            public MSSQL.Field Opt_OnlinePay_CBPayMent_UserNumber;
            public MSSQL.Field Opt_OnlinePay_CBPayMent_MD5Key;
            public MSSQL.Field Opt_OnlinePay_CBPayMent_PayFormalitiesFeesScale;
            public MSSQL.Field Opt_OnlinePayOut_CBPayMent_MD5Key;
            public MSSQL.Field Opt_OnlinePayOut_CBPayMent_DistillFormalitiesFeesScale;
            public MSSQL.Field Opt_AlipayOnlinePaySetting;
            public MSSQL.Field Opt_OnlinePayOut_Alipay_UserName;
            public MSSQL.Field Opt_OnlinePayOut_Alipay_UserNumber;
            public MSSQL.Field Opt_OnlinePayOut_Alipay_RealityName;

            public tbl_Shop()
            {
                TableName = "tbl_Shop";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ParentID = new MSSQL.Field(this, "ParentID", "ParentID", SqlDbType.BigInt, false);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                ShopTypeID = new MSSQL.Field(this, "ShopTypeID", "ShopTypeID", SqlDbType.Int, false);
                ShopNo = new MSSQL.Field(this, "ShopNo", "ShopNo", SqlDbType.VarChar, false);
                ShopName = new MSSQL.Field(this, "ShopName", "ShopName", SqlDbType.VarChar, false);
                Tel = new MSSQL.Field(this, "Tel", "Tel", SqlDbType.VarChar, false);
                Mobile = new MSSQL.Field(this, "Mobile", "Mobile", SqlDbType.VarChar, false);
                QQ = new MSSQL.Field(this, "QQ", "QQ", SqlDbType.VarChar, false);
                Email = new MSSQL.Field(this, "Email", "Email", SqlDbType.VarChar, false);
                PostCode = new MSSQL.Field(this, "PostCode", "PostCode", SqlDbType.VarChar, false);
                CityID = new MSSQL.Field(this, "CityID", "CityID", SqlDbType.Int, false);
                Address = new MSSQL.Field(this, "Address", "Address", SqlDbType.VarChar, false);
                Fax = new MSSQL.Field(this, "Fax", "Fax", SqlDbType.VarChar, false);
                Other = new MSSQL.Field(this, "Other", "Other", SqlDbType.VarChar, false);
                BankName = new MSSQL.Field(this, "BankName", "BankName", SqlDbType.VarChar, false);
                BankNameDetail = new MSSQL.Field(this, "BankNameDetail", "BankNameDetail", SqlDbType.VarChar, false);
                BankCustName = new MSSQL.Field(this, "BankCustName", "BankCustName", SqlDbType.VarChar, false);
                BankCardNo = new MSSQL.Field(this, "BankCardNo", "BankCardNo", SqlDbType.VarChar, false);
                RegisterOperID = new MSSQL.Field(this, "RegisterOperID", "RegisterOperID", SqlDbType.BigInt, false);
                RegisterDate = new MSSQL.Field(this, "RegisterDate", "RegisterDate", SqlDbType.DateTime, false);
                VerfyOperatorID = new MSSQL.Field(this, "VerfyOperatorID", "VerfyOperatorID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                SiteTitle = new MSSQL.Field(this, "SiteTitle", "SiteTitle", SqlDbType.VarChar, false);
                SiteURL = new MSSQL.Field(this, "SiteURL", "SiteURL", SqlDbType.VarChar, false);
                SiteStatus = new MSSQL.Field(this, "SiteStatus", "SiteStatus", SqlDbType.Int, false);
                SiteQQ = new MSSQL.Field(this, "SiteQQ", "SiteQQ", SqlDbType.VarChar, false);
                SiteTelephone = new MSSQL.Field(this, "SiteTelephone", "SiteTelephone", SqlDbType.VarChar, false);
                SiteCnzz = new MSSQL.Field(this, "SiteCnzz", "SiteCnzz", SqlDbType.VarChar, false);
                SiteScript = new MSSQL.Field(this, "SiteScript", "SiteScript", SqlDbType.VarChar, false);
                SiteService = new MSSQL.Field(this, "SiteService", "SiteService", SqlDbType.VarChar, false);
                QQ1 = new MSSQL.Field(this, "QQ1", "QQ1", SqlDbType.VarChar, false);
                QQ2 = new MSSQL.Field(this, "QQ2", "QQ2", SqlDbType.VarChar, false);
                CopyRightInfo = new MSSQL.Field(this, "CopyRightInfo", "CopyRightInfo", SqlDbType.VarChar, false);
                ICPCert = new MSSQL.Field(this, "ICPCert", "ICPCert", SqlDbType.VarChar, false);
                PV = new MSSQL.Field(this, "PV", "PV", SqlDbType.Money, false);
                BV = new MSSQL.Field(this, "BV", "BV", SqlDbType.Money, false);
                EnterpriseWebSite = new MSSQL.Field(this, "EnterpriseWebSite", "EnterpriseWebSite", SqlDbType.VarChar, false);
                EnterpriseWebStatus = new MSSQL.Field(this, "EnterpriseWebStatus", "EnterpriseWebStatus", SqlDbType.Int, false);
                Opt_isWriteLog = new MSSQL.Field(this, "Opt_isWriteLog", "Opt_isWriteLog", SqlDbType.Bit, false);
                Opt_isUseCheckCode = new MSSQL.Field(this, "Opt_isUseCheckCode", "Opt_isUseCheckCode", SqlDbType.Bit, false);
                Opt_CheckCodeCharset = new MSSQL.Field(this, "Opt_CheckCodeCharset", "Opt_CheckCodeCharset", SqlDbType.SmallInt, false);
                Opt_MemberSharing_Alipay_Status_ON = new MSSQL.Field(this, "Opt_MemberSharing_Alipay_Status_ON", "Opt_MemberSharing_Alipay_Status_ON", SqlDbType.Bit, false);
                Opt_MemberSharing_Alipay_Gateway = new MSSQL.Field(this, "Opt_MemberSharing_Alipay_Gateway", "Opt_MemberSharing_Alipay_Gateway", SqlDbType.VarChar, false);
                Opt_MemberSharing_Alipay_UserNumber = new MSSQL.Field(this, "Opt_MemberSharing_Alipay_UserNumber", "Opt_MemberSharing_Alipay_UserNumber", SqlDbType.VarChar, false);
                Opt_MemberSharing_Alipay_UserPassword = new MSSQL.Field(this, "Opt_MemberSharing_Alipay_UserPassword", "Opt_MemberSharing_Alipay_UserPassword", SqlDbType.VarChar, false);
                Opt_MemberSharing_Alipay_MD5 = new MSSQL.Field(this, "Opt_MemberSharing_Alipay_MD5", "Opt_MemberSharing_Alipay_MD5", SqlDbType.VarChar, false);
                Opt_OnlinePay_Alipay_Status_ON = new MSSQL.Field(this, "Opt_OnlinePay_Alipay_Status_ON", "Opt_OnlinePay_Alipay_Status_ON", SqlDbType.Bit, false);
                Opt_OnlinePay_Alipay_UserName = new MSSQL.Field(this, "Opt_OnlinePay_Alipay_UserName", "Opt_OnlinePay_Alipay_UserName", SqlDbType.VarChar, false);
                Opt_OnlinePay_Alipay_UserNumber = new MSSQL.Field(this, "Opt_OnlinePay_Alipay_UserNumber", "Opt_OnlinePay_Alipay_UserNumber", SqlDbType.VarChar, false);
                Opt_OnlinePay_Alipay_MD5Key = new MSSQL.Field(this, "Opt_OnlinePay_Alipay_MD5Key", "Opt_OnlinePay_Alipay_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePay_Alipay_PayFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePay_Alipay_PayFormalitiesFeesScale", "Opt_OnlinePay_Alipay_PayFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Alipay_MD5Key = new MSSQL.Field(this, "Opt_OnlinePayOut_Alipay_MD5Key", "Opt_OnlinePayOut_Alipay_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Alipay_DistillFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePayOut_Alipay_DistillFormalitiesFeesScale", "Opt_OnlinePayOut_Alipay_DistillFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePay_99Bill_Status_ON = new MSSQL.Field(this, "Opt_OnlinePay_99Bill_Status_ON", "Opt_OnlinePay_99Bill_Status_ON", SqlDbType.Bit, false);
                Opt_OnlinePay_99Bill_UserName = new MSSQL.Field(this, "Opt_OnlinePay_99Bill_UserName", "Opt_OnlinePay_99Bill_UserName", SqlDbType.VarChar, false);
                Opt_OnlinePay_99Bill_UserNumber = new MSSQL.Field(this, "Opt_OnlinePay_99Bill_UserNumber", "Opt_OnlinePay_99Bill_UserNumber", SqlDbType.VarChar, false);
                Opt_OnlinePay_99Bill_MD5Key = new MSSQL.Field(this, "Opt_OnlinePay_99Bill_MD5Key", "Opt_OnlinePay_99Bill_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePay_99Bill_PayFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePay_99Bill_PayFormalitiesFeesScale", "Opt_OnlinePay_99Bill_PayFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_99Bill_MD5Key = new MSSQL.Field(this, "Opt_OnlinePayOut_99Bill_MD5Key", "Opt_OnlinePayOut_99Bill_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_99Bill_DistillFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePayOut_99Bill_DistillFormalitiesFeesScale", "Opt_OnlinePayOut_99Bill_DistillFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePay_Tenpay_Status_ON = new MSSQL.Field(this, "Opt_OnlinePay_Tenpay_Status_ON", "Opt_OnlinePay_Tenpay_Status_ON", SqlDbType.Bit, false);
                Opt_OnlinePay_Tenpay_UserName = new MSSQL.Field(this, "Opt_OnlinePay_Tenpay_UserName", "Opt_OnlinePay_Tenpay_UserName", SqlDbType.VarChar, false);
                Opt_OnlinePay_Tenpay_UserNumber = new MSSQL.Field(this, "Opt_OnlinePay_Tenpay_UserNumber", "Opt_OnlinePay_Tenpay_UserNumber", SqlDbType.VarChar, false);
                Opt_OnlinePay_Tenpay_MD5Key = new MSSQL.Field(this, "Opt_OnlinePay_Tenpay_MD5Key", "Opt_OnlinePay_Tenpay_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePay_Tenpay_PayFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePay_Tenpay_PayFormalitiesFeesScale", "Opt_OnlinePay_Tenpay_PayFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Tenpay_MD5Key = new MSSQL.Field(this, "Opt_OnlinePayOut_Tenpay_MD5Key", "Opt_OnlinePayOut_Tenpay_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Tenpay_DistillFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePayOut_Tenpay_DistillFormalitiesFeesScale", "Opt_OnlinePayOut_Tenpay_DistillFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePay_CBPayMent_Status_ON = new MSSQL.Field(this, "Opt_OnlinePay_CBPayMent_Status_ON", "Opt_OnlinePay_CBPayMent_Status_ON", SqlDbType.Bit, false);
                Opt_OnlinePay_CBPayMent_UserName = new MSSQL.Field(this, "Opt_OnlinePay_CBPayMent_UserName", "Opt_OnlinePay_CBPayMent_UserName", SqlDbType.VarChar, false);
                Opt_OnlinePay_CBPayMent_UserNumber = new MSSQL.Field(this, "Opt_OnlinePay_CBPayMent_UserNumber", "Opt_OnlinePay_CBPayMent_UserNumber", SqlDbType.VarChar, false);
                Opt_OnlinePay_CBPayMent_MD5Key = new MSSQL.Field(this, "Opt_OnlinePay_CBPayMent_MD5Key", "Opt_OnlinePay_CBPayMent_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePay_CBPayMent_PayFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePay_CBPayMent_PayFormalitiesFeesScale", "Opt_OnlinePay_CBPayMent_PayFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_CBPayMent_MD5Key = new MSSQL.Field(this, "Opt_OnlinePayOut_CBPayMent_MD5Key", "Opt_OnlinePayOut_CBPayMent_MD5Key", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_CBPayMent_DistillFormalitiesFeesScale = new MSSQL.Field(this, "Opt_OnlinePayOut_CBPayMent_DistillFormalitiesFeesScale", "Opt_OnlinePayOut_CBPayMent_DistillFormalitiesFeesScale", SqlDbType.VarChar, false);
                Opt_AlipayOnlinePaySetting = new MSSQL.Field(this, "Opt_AlipayOnlinePaySetting", "Opt_AlipayOnlinePaySetting", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Alipay_UserName = new MSSQL.Field(this, "Opt_OnlinePayOut_Alipay_UserName", "Opt_OnlinePayOut_Alipay_UserName", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Alipay_UserNumber = new MSSQL.Field(this, "Opt_OnlinePayOut_Alipay_UserNumber", "Opt_OnlinePayOut_Alipay_UserNumber", SqlDbType.VarChar, false);
                Opt_OnlinePayOut_Alipay_RealityName = new MSSQL.Field(this, "Opt_OnlinePayOut_Alipay_RealityName", "Opt_OnlinePayOut_Alipay_RealityName", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_LossMaster : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field LossNo;
            public MSSQL.Field InvoiceID;
            public MSSQL.Field CreateShopID;
            public MSSQL.Field SourceShopID;
            public MSSQL.Field TargetShopID;
            public MSSQL.Field LossType;
            public MSSQL.Field Status;
            public MSSQL.Field CreateOperID;
            public MSSQL.Field CreateDate;
            public MSSQL.Field VerfyOperID;
            public MSSQL.Field VerfyDate;
            public MSSQL.Field Remark;
            public MSSQL.Field Money;
            public MSSQL.Field ActualMoney;

            public tbl_Shop_LossMaster()
            {
                TableName = "tbl_Shop_LossMaster";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                LossNo = new MSSQL.Field(this, "LossNo", "LossNo", SqlDbType.VarChar, false);
                InvoiceID = new MSSQL.Field(this, "InvoiceID", "InvoiceID", SqlDbType.VarChar, false);
                CreateShopID = new MSSQL.Field(this, "CreateShopID", "CreateShopID", SqlDbType.BigInt, false);
                SourceShopID = new MSSQL.Field(this, "SourceShopID", "SourceShopID", SqlDbType.BigInt, false);
                TargetShopID = new MSSQL.Field(this, "TargetShopID", "TargetShopID", SqlDbType.BigInt, false);
                LossType = new MSSQL.Field(this, "LossType", "LossType", SqlDbType.TinyInt, false);
                Status = new MSSQL.Field(this, "Status", "Status", SqlDbType.TinyInt, false);
                CreateOperID = new MSSQL.Field(this, "CreateOperID", "CreateOperID", SqlDbType.BigInt, false);
                CreateDate = new MSSQL.Field(this, "CreateDate", "CreateDate", SqlDbType.DateTime, false);
                VerfyOperID = new MSSQL.Field(this, "VerfyOperID", "VerfyOperID", SqlDbType.BigInt, false);
                VerfyDate = new MSSQL.Field(this, "VerfyDate", "VerfyDate", SqlDbType.DateTime, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Float, false);
                ActualMoney = new MSSQL.Field(this, "ActualMoney", "ActualMoney", SqlDbType.Float, false);
            }
        }

        public class tbl_Information : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field Title;
            public MSSQL.Field Content;
            public MSSQL.Field isShow;
            public MSSQL.Field Type;

            public tbl_Information()
            {
                TableName = "tbl_Information";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.Int, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                Title = new MSSQL.Field(this, "Title", "Title", SqlDbType.VarChar, false);
                Content = new MSSQL.Field(this, "Content", "Content", SqlDbType.Image, false);
                isShow = new MSSQL.Field(this, "isShow", "isShow", SqlDbType.Bit, false);
                Type = new MSSQL.Field(this, "Type", "Type", SqlDbType.Int, false);
            }
        }

        public class tbl_Shop_InventoryDetail : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field InventoryID;
            public MSSQL.Field GoodID;
            public MSSQL.Field GoodNo;
            public MSSQL.Field BrandID;
            public MSSQL.Field GoodTypeID;
            public MSSQL.Field GoodName_CN;
            public MSSQL.Field GoodName_EN;
            public MSSQL.Field Price_Orig;
            public MSSQL.Field Price_Vip;
            public MSSQL.Field Price_BV;
            public MSSQL.Field Price_Lastin;
            public MSSQL.Field GoodNorm;
            public MSSQL.Field GoodUnit;
            public MSSQL.Field GoodColor;
            public MSSQL.Field GoodPic_Big;
            public MSSQL.Field GoodPic_Small;
            public MSSQL.Field GoodIntroduce;
            public MSSQL.Field GoodIntroduce_Detail;
            public MSSQL.Field TransportLossRate;
            public MSSQL.Field SaleLossRate;
            public MSSQL.Field ActualPrice;
            public MSSQL.Field Amount;
            public MSSQL.Field ActualAmount;
            public MSSQL.Field ShopID;

            public tbl_Shop_InventoryDetail()
            {
                TableName = "tbl_Shop_InventoryDetail";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                InventoryID = new MSSQL.Field(this, "InventoryID", "InventoryID", SqlDbType.BigInt, false);
                GoodID = new MSSQL.Field(this, "GoodID", "GoodID", SqlDbType.BigInt, false);
                GoodNo = new MSSQL.Field(this, "GoodNo", "GoodNo", SqlDbType.VarChar, false);
                BrandID = new MSSQL.Field(this, "BrandID", "BrandID", SqlDbType.Int, false);
                GoodTypeID = new MSSQL.Field(this, "GoodTypeID", "GoodTypeID", SqlDbType.VarChar, false);
                GoodName_CN = new MSSQL.Field(this, "GoodName_CN", "GoodName_CN", SqlDbType.VarChar, false);
                GoodName_EN = new MSSQL.Field(this, "GoodName_EN", "GoodName_EN", SqlDbType.VarChar, false);
                Price_Orig = new MSSQL.Field(this, "Price_Orig", "Price_Orig", SqlDbType.Float, false);
                Price_Vip = new MSSQL.Field(this, "Price_Vip", "Price_Vip", SqlDbType.Float, false);
                Price_BV = new MSSQL.Field(this, "Price_BV", "Price_BV", SqlDbType.Float, false);
                Price_Lastin = new MSSQL.Field(this, "Price_Lastin", "Price_Lastin", SqlDbType.Float, false);
                GoodNorm = new MSSQL.Field(this, "GoodNorm", "GoodNorm", SqlDbType.VarChar, false);
                GoodUnit = new MSSQL.Field(this, "GoodUnit", "GoodUnit", SqlDbType.VarChar, false);
                GoodColor = new MSSQL.Field(this, "GoodColor", "GoodColor", SqlDbType.VarChar, false);
                GoodPic_Big = new MSSQL.Field(this, "GoodPic_Big", "GoodPic_Big", SqlDbType.VarChar, false);
                GoodPic_Small = new MSSQL.Field(this, "GoodPic_Small", "GoodPic_Small", SqlDbType.VarChar, false);
                GoodIntroduce = new MSSQL.Field(this, "GoodIntroduce", "GoodIntroduce", SqlDbType.VarChar, false);
                GoodIntroduce_Detail = new MSSQL.Field(this, "GoodIntroduce_Detail", "GoodIntroduce_Detail", SqlDbType.VarChar, false);
                TransportLossRate = new MSSQL.Field(this, "TransportLossRate", "TransportLossRate", SqlDbType.Float, false);
                SaleLossRate = new MSSQL.Field(this, "SaleLossRate", "SaleLossRate", SqlDbType.Float, false);
                ActualPrice = new MSSQL.Field(this, "ActualPrice", "ActualPrice", SqlDbType.Float, false);
                Amount = new MSSQL.Field(this, "Amount", "Amount", SqlDbType.Int, false);
                ActualAmount = new MSSQL.Field(this, "ActualAmount", "ActualAmount", SqlDbType.Int, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }

        public class tbl_CustomerDetailsLog : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field CustomerID;
            public MSSQL.Field DateTime;
            public MSSQL.Field OperatorType;
            public MSSQL.Field Money;
            public MSSQL.Field RelatedCustomerID;
            public MSSQL.Field OperatorID;
            public MSSQL.Field Memo;

            public tbl_CustomerDetailsLog()
            {
                TableName = "tbl_CustomerDetailsLog";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                CustomerID = new MSSQL.Field(this, "CustomerID", "CustomerID", SqlDbType.BigInt, false);
                DateTime = new MSSQL.Field(this, "DateTime", "DateTime", SqlDbType.DateTime, false);
                OperatorType = new MSSQL.Field(this, "OperatorType", "OperatorType", SqlDbType.SmallInt, false);
                Money = new MSSQL.Field(this, "Money", "Money", SqlDbType.Money, false);
                RelatedCustomerID = new MSSQL.Field(this, "RelatedCustomerID", "RelatedCustomerID", SqlDbType.BigInt, false);
                OperatorID = new MSSQL.Field(this, "OperatorID", "OperatorID", SqlDbType.BigInt, false);
                Memo = new MSSQL.Field(this, "Memo", "Memo", SqlDbType.VarChar, false);
            }
        }

        public class tbl_WaitSendEmail : MSSQL.TableBase
        {
            public MSSQL.Field id;
            public MSSQL.Field MailTo;
            public MSSQL.Field Subject;
            public MSSQL.Field Body;
            public MSSQL.Field isSended;
            public MSSQL.Field Result;

            public tbl_WaitSendEmail()
            {
                TableName = "tbl_WaitSendEmail";

                id = new MSSQL.Field(this, "id", "id", SqlDbType.BigInt, true);
                MailTo = new MSSQL.Field(this, "MailTo", "MailTo", SqlDbType.Image, false);
                Subject = new MSSQL.Field(this, "Subject", "Subject", SqlDbType.Image, false);
                Body = new MSSQL.Field(this, "Body", "Body", SqlDbType.Image, false);
                isSended = new MSSQL.Field(this, "isSended", "isSended", SqlDbType.Bit, false);
                Result = new MSSQL.Field(this, "Result", "Result", SqlDbType.Int, false);
            }
        }

        public class tbl_Site_HotSpot : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field ShopID;
            public MSSQL.Field Name;

            public tbl_Site_HotSpot()
            {
                TableName = "tbl_Site_HotSpot";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.BigInt, true);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
                Name = new MSSQL.Field(this, "Name", "Name", SqlDbType.VarChar, false);
            }
        }

        public class tbl_Shop_GoodType : MSSQL.TableBase
        {
            public MSSQL.Field ID;
            public MSSQL.Field TypeName;
            public MSSQL.Field ParentID;
            public MSSQL.Field TypeStatus;
            public MSSQL.Field Introduce;
            public MSSQL.Field Remark;
            public MSSQL.Field ShopID;

            public tbl_Shop_GoodType()
            {
                TableName = "tbl_Shop_GoodType";

                ID = new MSSQL.Field(this, "ID", "ID", SqlDbType.VarChar, false);
                TypeName = new MSSQL.Field(this, "TypeName", "TypeName", SqlDbType.VarChar, false);
                ParentID = new MSSQL.Field(this, "ParentID", "ParentID", SqlDbType.VarChar, false);
                TypeStatus = new MSSQL.Field(this, "TypeStatus", "TypeStatus", SqlDbType.TinyInt, false);
                Introduce = new MSSQL.Field(this, "Introduce", "Introduce", SqlDbType.VarChar, false);
                Remark = new MSSQL.Field(this, "Remark", "Remark", SqlDbType.VarChar, false);
                ShopID = new MSSQL.Field(this, "ShopID", "ShopID", SqlDbType.BigInt, false);
            }
        }
    }

    public class Views
    {
        public class V_CustomerConsumer : MSSQL.ViewBase
        {
            public V_CustomerConsumer()
            {
                ViewName = "V_CustomerConsumer";
            }
        }

        public class V_Earning : MSSQL.ViewBase
        {
            public V_Earning()
            {
                ViewName = "V_Earning";
            }
        }

        public class V_Site_GoodShopStock : MSSQL.ViewBase
        {
            public V_Site_GoodShopStock()
            {
                ViewName = "V_Site_GoodShopStock";
            }
        }

        public class V_Site_Article : MSSQL.ViewBase
        {
            public V_Site_Article()
            {
                ViewName = "V_Site_Article";
            }
        }

        public class V_Shop_ShipmentMaster : MSSQL.ViewBase
        {
            public V_Shop_ShipmentMaster()
            {
                ViewName = "V_Shop_ShipmentMaster";
            }
        }

        public class V_MessageBoardCopy : MSSQL.ViewBase
        {
            public V_MessageBoardCopy()
            {
                ViewName = "V_MessageBoardCopy";
            }
        }

        public class V_MessageBoard : MSSQL.ViewBase
        {
            public V_MessageBoard()
            {
                ViewName = "V_MessageBoard";
            }
        }

        public class V_Shop_LossMaster : MSSQL.ViewBase
        {
            public V_Shop_LossMaster()
            {
                ViewName = "V_Shop_LossMaster";
            }
        }

        public class V_LoginLog : MSSQL.ViewBase
        {
            public V_LoginLog()
            {
                ViewName = "V_LoginLog";
            }
        }

        public class V_Shop_InventoryMaster : MSSQL.ViewBase
        {
            public V_Shop_InventoryMaster()
            {
                ViewName = "V_Shop_InventoryMaster";
            }
        }

        public class V_Shop_GoodExpand : MSSQL.ViewBase
        {
            public V_Shop_GoodExpand()
            {
                ViewName = "V_Shop_GoodExpand";
            }
        }

        public class V_CustomerDetails : MSSQL.ViewBase
        {
            public V_CustomerDetails()
            {
                ViewName = "V_CustomerDetails";
            }
        }

        public class V_Site_GoodComment : MSSQL.ViewBase
        {
            public V_Site_GoodComment()
            {
                ViewName = "V_Site_GoodComment";
            }
        }

        public class V_Shop_Good : MSSQL.ViewBase
        {
            public V_Shop_Good()
            {
                ViewName = "V_Shop_Good";
            }
        }

        public class V_Shop_ShopStock : MSSQL.ViewBase
        {
            public V_Shop_ShopStock()
            {
                ViewName = "V_Shop_ShopStock";
            }
        }

        public class V_Site_FatoviteGood : MSSQL.ViewBase
        {
            public V_Site_FatoviteGood()
            {
                ViewName = "V_Site_FatoviteGood";
            }
        }

        public class V_Shop_DepotOutMaster : MSSQL.ViewBase
        {
            public V_Shop_DepotOutMaster()
            {
                ViewName = "V_Shop_DepotOutMaster";
            }
        }

        public class V_Shop_DepotINMaster : MSSQL.ViewBase
        {
            public V_Shop_DepotINMaster()
            {
                ViewName = "V_Shop_DepotINMaster";
            }
        }

        public class V_City : MSSQL.ViewBase
        {
            public V_City()
            {
                ViewName = "V_City";
            }
        }

        public class V_Customer : MSSQL.ViewBase
        {
            public V_Customer()
            {
                ViewName = "V_Customer";
            }
        }

        public class V_CustomerDistill : MSSQL.ViewBase
        {
            public V_CustomerDistill()
            {
                ViewName = "V_CustomerDistill";
            }
        }

        public class V_Shop_SalesMaster : MSSQL.ViewBase
        {
            public V_Shop_SalesMaster()
            {
                ViewName = "V_Shop_SalesMaster";
            }
        }

        public class V_Shop_SalesDetail : MSSQL.ViewBase
        {
            public V_Shop_SalesDetail()
            {
                ViewName = "V_Shop_SalesDetail";
            }
        }

        public class V_Shop_RequestGoodMaster : MSSQL.ViewBase
        {
            public V_Shop_RequestGoodMaster()
            {
                ViewName = "V_Shop_RequestGoodMaster";
            }
        }

        public class V_Department : MSSQL.ViewBase
        {
            public V_Department()
            {
                ViewName = "V_Department";
            }
        }

        public class V_Shop : MSSQL.ViewBase
        {
            public V_Shop()
            {
                ViewName = "V_Shop";
            }
        }

        public class V_Shop_BackGoodMaster : MSSQL.ViewBase
        {
            public V_Shop_BackGoodMaster()
            {
                ViewName = "V_Shop_BackGoodMaster";
            }
        }

        public class V_Shop_AllocateMaster : MSSQL.ViewBase
        {
            public V_Shop_AllocateMaster()
            {
                ViewName = "V_Shop_AllocateMaster";
            }
        }

        public class V_Shop_TopSales : MSSQL.ViewBase
        {
            public V_Shop_TopSales()
            {
                ViewName = "V_Shop_TopSales";
            }
        }
    }

    public class Functions
    {
        public static DataTable F_GetWeekByYear(int Year)
        {
            return MSSQL.Select("select * from F_GetWeekByYear(@Year)",
                new MSSQL.Parameter("Year", SqlDbType.Int, 0, ParameterDirection.Input, Year)
                );
        }

        public static string F_Shop_DateTimeToString(DateTime Date)
        {
            object Result = MSSQL.ExecuteFunction("F_Shop_DateTimeToString",
                new MSSQL.Parameter("Date", SqlDbType.DateTime, 0, ParameterDirection.Input, Date)
                );

            return System.Convert.ToString(Result);
        }

        public static int F_GetCustomerBumpedSum(long CustomerID)
        {
            object Result = MSSQL.ExecuteFunction("F_GetCustomerBumpedSum",
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID)
                );

            return System.Convert.ToInt32(Result);
        }

        public static int F_YMDToInt(int year, int month, int day)
        {
            object Result = MSSQL.ExecuteFunction("F_YMDToInt",
                new MSSQL.Parameter("year", SqlDbType.Int, 0, ParameterDirection.Input, year),
                new MSSQL.Parameter("month", SqlDbType.Int, 0, ParameterDirection.Input, month),
                new MSSQL.Parameter("day", SqlDbType.Int, 0, ParameterDirection.Input, day)
                );

            return System.Convert.ToInt32(Result);
        }

        public static DataTable F_SplitString(string SplitString, string Separator)
        {
            return MSSQL.Select("select * from F_SplitString(@SplitString, @Separator)",
                new MSSQL.Parameter("SplitString", SqlDbType.VarChar, 0, ParameterDirection.Input, SplitString),
                new MSSQL.Parameter("Separator", SqlDbType.VarChar, 0, ParameterDirection.Input, Separator)
                );
        }

        public static int F_DateTimeToInt(DateTime dt)
        {
            object Result = MSSQL.ExecuteFunction("F_DateTimeToInt",
                new MSSQL.Parameter("dt", SqlDbType.DateTime, 0, ParameterDirection.Input, dt)
                );

            return System.Convert.ToInt32(Result);
        }

        public static DataTable F_GetUserNet(long ID)
        {
            return MSSQL.Select("select * from F_GetUserNet(@ID)",
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );
        }

        public static byte[] F_GetOptionBinary(string Key)
        {
            object Result = MSSQL.ExecuteFunction("F_GetOptionBinary",
                new MSSQL.Parameter("Key", SqlDbType.VarChar, 0, ParameterDirection.Input, Key)
                );

            return (byte[])(Result);
        }

        public static string F_GetOption(string Key)
        {
            object Result = MSSQL.ExecuteFunction("F_GetOption",
                new MSSQL.Parameter("Key", SqlDbType.VarChar, 0, ParameterDirection.Input, Key)
                );

            return System.Convert.ToString(Result);
        }

        public static int F_GetCustomerBumpedSumForToday(long CustomerID, DateTime Datetime)
        {
            object Result = MSSQL.ExecuteFunction("F_GetCustomerBumpedSumForToday",
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Datetime", SqlDbType.DateTime, 0, ParameterDirection.Input, Datetime)
                );

            return System.Convert.ToInt32(Result);
        }

        public static DataTable F_GetSiteAdministrators(long SiteID)
        {
            return MSSQL.Select("select * from F_GetSiteAdministrators(@SiteID)",
                new MSSQL.Parameter("SiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, SiteID)
                );
        }

        public static DataTable F_GetManagers(long SiteID)
        {
            return MSSQL.Select("select * from F_GetManagers(@SiteID)",
                new MSSQL.Parameter("SiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, SiteID)
                );
        }

        public static string F_GetCustomerCompetencesList(long CustomerID)
        {
            object Result = MSSQL.ExecuteFunction("F_GetCustomerCompetencesList",
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID)
                );

            return System.Convert.ToString(Result);
        }
    }

    public class Procedures
    {
        public static int P_CustomerAdd(string CustomerNo, string CustomerName, short CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNumber, string BankCustName, int DeptID, long RegisterOperID, string Remark, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, short LR, bool AutoNext, bool isLock, bool isActivation, bool IsSurrogate, ref long CustomerID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerAdd(ref ds, CustomerNo, CustomerName, CustomerTypeID, Password1, Password2, Tel, Mobile, QQ, Email, PostCode, CityID, Address, Fax, Other, Sex, Birthday, CertTypeID, CertNo, BankTypeID, BankNameDetail, BankCardNumber, BankCustName, DeptID, RegisterOperID, Remark, RegisterShopID, SurrogateID, CommendID, ParentID, LR, AutoNext, isLock, isActivation, IsSurrogate, ref CustomerID, ref ReturnDescription);
        }

        public static int P_CustomerAdd(ref DataSet ds, string CustomerNo, string CustomerName, short CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNumber, string BankCustName, int DeptID, long RegisterOperID, string Remark, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, short LR, bool AutoNext, bool isLock, bool isActivation, bool IsSurrogate, ref long CustomerID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerAdd", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerNo),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CustomerTypeID),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 0, ParameterDirection.Input, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 0, ParameterDirection.Input, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 0, ParameterDirection.Input, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 0, ParameterDirection.Input, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 0, ParameterDirection.Input, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 0, ParameterDirection.Input, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 0, ParameterDirection.Input, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 0, ParameterDirection.Input, CityID),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 0, ParameterDirection.Input, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 0, ParameterDirection.Input, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 0, ParameterDirection.Input, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 0, ParameterDirection.Input, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 0, ParameterDirection.Input, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CertTypeID),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 0, ParameterDirection.Input, BankTypeID),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 0, ParameterDirection.Input, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCustName),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 0, ParameterDirection.Input, DeptID),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterOperID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterShopID),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 0, ParameterDirection.Input, CommendID),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 0, ParameterDirection.Input, ParentID),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 0, ParameterDirection.Input, LR),
                new MSSQL.Parameter("AutoNext", SqlDbType.Bit, 0, ParameterDirection.Input, AutoNext),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 0, ParameterDirection.Input, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 0, ParameterDirection.Input, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 0, ParameterDirection.Input, IsSurrogate),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetOrderNO(string DBOrderNO, string OrderTable, ref string OrderNO)
        {
            DataSet ds = null;

            return P_GetOrderNO(ref ds, DBOrderNO, OrderTable, ref OrderNO);
        }

        public static int P_GetOrderNO(ref DataSet ds, string DBOrderNO, string OrderTable, ref string OrderNO)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetOrderNO", ref ds, ref Outputs,
                new MSSQL.Parameter("DBOrderNO", SqlDbType.VarChar, 0, ParameterDirection.Input, DBOrderNO),
                new MSSQL.Parameter("OrderTable", SqlDbType.VarChar, 0, ParameterDirection.Input, OrderTable),
                new MSSQL.Parameter("OrderNO", SqlDbType.VarChar, 50, ParameterDirection.Output, OrderNO)
                );

            try
            {
                OrderNO = System.Convert.ToString(Outputs["OrderNO"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_GetShipmentInvoiceNOByID(long ID, ref string InvoiceNO)
        {
            DataSet ds = null;

            return P_Shop_GetShipmentInvoiceNOByID(ref ds, ID, ref InvoiceNO);
        }

        public static int P_Shop_GetShipmentInvoiceNOByID(ref DataSet ds, long ID, ref string InvoiceNO)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_GetShipmentInvoiceNOByID", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("InvoiceNO", SqlDbType.VarChar, 50, ParameterDirection.Output, InvoiceNO)
                );

            try
            {
                InvoiceNO = System.Convert.ToString(Outputs["InvoiceNO"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Site_ShopAddSales_Master(long CustomerID, long CreateShopID, long CreateOperID, short SalesType, string Remark, int PayType, int CarriageType, string ConsigneeName, string ConsigneeTel, string ConsigneeMobile, string ConsigneeEmail, string ConsigneeZipCode, string ConsigneeAdress, bool IsTicket, long SiteID, ref long NowID)
        {
            DataSet ds = null;

            return P_Site_ShopAddSales_Master(ref ds, CustomerID, CreateShopID, CreateOperID, SalesType, Remark, PayType, CarriageType, ConsigneeName, ConsigneeTel, ConsigneeMobile, ConsigneeEmail, ConsigneeZipCode, ConsigneeAdress, IsTicket, SiteID, ref NowID);
        }

        public static int P_Site_ShopAddSales_Master(ref DataSet ds, long CustomerID, long CreateShopID, long CreateOperID, short SalesType, string Remark, int PayType, int CarriageType, string ConsigneeName, string ConsigneeTel, string ConsigneeMobile, string ConsigneeEmail, string ConsigneeZipCode, string ConsigneeAdress, bool IsTicket, long SiteID, ref long NowID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_ShopAddSales_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("SalesType", SqlDbType.TinyInt, 0, ParameterDirection.Input, SalesType),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("PayType", SqlDbType.Int, 0, ParameterDirection.Input, PayType),
                new MSSQL.Parameter("CarriageType", SqlDbType.Int, 0, ParameterDirection.Input, CarriageType),
                new MSSQL.Parameter("ConsigneeName", SqlDbType.VarChar, 0, ParameterDirection.Input, ConsigneeName),
                new MSSQL.Parameter("ConsigneeTel", SqlDbType.VarChar, 0, ParameterDirection.Input, ConsigneeTel),
                new MSSQL.Parameter("ConsigneeMobile", SqlDbType.VarChar, 0, ParameterDirection.Input, ConsigneeMobile),
                new MSSQL.Parameter("ConsigneeEmail", SqlDbType.VarChar, 0, ParameterDirection.Input, ConsigneeEmail),
                new MSSQL.Parameter("ConsigneeZipCode", SqlDbType.VarChar, 0, ParameterDirection.Input, ConsigneeZipCode),
                new MSSQL.Parameter("ConsigneeAdress", SqlDbType.VarChar, 0, ParameterDirection.Input, ConsigneeAdress),
                new MSSQL.Parameter("IsTicket", SqlDbType.Bit, 0, ParameterDirection.Input, IsTicket),
                new MSSQL.Parameter("SiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, SiteID),
                new MSSQL.Parameter("NowID", SqlDbType.BigInt, 8, ParameterDirection.Output, NowID)
                );

            try
            {
                NowID = System.Convert.ToInt64(Outputs["NowID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_DistillEarning3(int DistillType, long Earning3ID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_DistillEarning3(ref ds, DistillType, Earning3ID, ref ReturnDescription);
        }

        public static int P_DistillEarning3(ref DataSet ds, int DistillType, long Earning3ID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DistillEarning3", ref ds, ref Outputs,
                new MSSQL.Parameter("DistillType", SqlDbType.Int, 0, ParameterDirection.Input, DistillType),
                new MSSQL.Parameter("Earning3ID", SqlDbType.BigInt, 0, ParameterDirection.Input, Earning3ID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetPVForCustomer(long CustomerID, ref double PV, ref double CountA, ref double CountB, ref double MonthA, ref double MonthB)
        {
            DataSet ds = null;

            return P_GetPVForCustomer(ref ds, CustomerID, ref PV, ref CountA, ref CountB, ref MonthA, ref MonthB);
        }

        public static int P_GetPVForCustomer(ref DataSet ds, long CustomerID, ref double PV, ref double CountA, ref double CountB, ref double MonthA, ref double MonthB)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetPVForCustomer", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("CountA", SqlDbType.Money, 8, ParameterDirection.Output, CountA),
                new MSSQL.Parameter("CountB", SqlDbType.Money, 8, ParameterDirection.Output, CountB),
                new MSSQL.Parameter("MonthA", SqlDbType.Money, 8, ParameterDirection.Output, MonthA),
                new MSSQL.Parameter("MonthB", SqlDbType.Money, 8, ParameterDirection.Output, MonthB)
                );

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                CountA = System.Convert.ToDouble(Outputs["CountA"]);
            }
            catch { }

            try
            {
                CountB = System.Convert.ToDouble(Outputs["CountB"]);
            }
            catch { }

            try
            {
                MonthA = System.Convert.ToDouble(Outputs["MonthA"]);
            }
            catch { }

            try
            {
                MonthB = System.Convert.ToDouble(Outputs["MonthB"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Earning3(DateTime DateTime)
        {
            DataSet ds = null;

            return P_Earning3(ref ds, DateTime);
        }

        public static int P_Earning3(ref DataSet ds, DateTime DateTime)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Earning3", ref ds, ref Outputs,
                new MSSQL.Parameter("DateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, DateTime)
                );

            return CallResult;
        }

        public static int P_Site_ShopOrderCancel(long SalesID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Site_ShopOrderCancel(ref ds, SalesID, VerfyOperID);
        }

        public static int P_Site_ShopOrderCancel(ref DataSet ds, long SalesID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_ShopOrderCancel", ref ds, ref Outputs,
                new MSSQL.Parameter("SalesID", SqlDbType.BigInt, 0, ParameterDirection.Input, SalesID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_Site_ShopOrderCheck(long SalesID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Site_ShopOrderCheck(ref ds, SalesID, VerfyOperID);
        }

        public static int P_Site_ShopOrderCheck(ref DataSet ds, long SalesID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_ShopOrderCheck", ref ds, ref Outputs,
                new MSSQL.Parameter("SalesID", SqlDbType.BigInt, 0, ParameterDirection.Input, SalesID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_Alipay_GetNewPayNumber(long ShopID, long CustomerID, string PayType, double Money, double FormalitiesFees, int RelatedOrderType, long RelatedOrderID, ref long NewPayNumber, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_Alipay_GetNewPayNumber(ref ds, ShopID, CustomerID, PayType, Money, FormalitiesFees, RelatedOrderType, RelatedOrderID, ref NewPayNumber, ref ReturnDescription);
        }

        public static int P_Alipay_GetNewPayNumber(ref DataSet ds, long ShopID, long CustomerID, string PayType, double Money, double FormalitiesFees, int RelatedOrderType, long RelatedOrderID, ref long NewPayNumber, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Alipay_GetNewPayNumber", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("PayType", SqlDbType.VarChar, 0, ParameterDirection.Input, PayType),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("FormalitiesFees", SqlDbType.Money, 0, ParameterDirection.Input, FormalitiesFees),
                new MSSQL.Parameter("RelatedOrderType", SqlDbType.Int, 0, ParameterDirection.Input, RelatedOrderType),
                new MSSQL.Parameter("RelatedOrderID", SqlDbType.BigInt, 0, ParameterDirection.Input, RelatedOrderID),
                new MSSQL.Parameter("NewPayNumber", SqlDbType.BigInt, 8, ParameterDirection.Output, NewPayNumber),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                NewPayNumber = System.Convert.ToInt64(Outputs["NewPayNumber"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Alipay_PaymentDefeatOnlyOne(long ID, int PaymentType, int OperatorType)
        {
            DataSet ds = null;

            return P_Alipay_PaymentDefeatOnlyOne(ref ds, ID, PaymentType, OperatorType);
        }

        public static int P_Alipay_PaymentDefeatOnlyOne(ref DataSet ds, long ID, int PaymentType, int OperatorType)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Alipay_PaymentDefeatOnlyOne", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("PaymentType", SqlDbType.Int, 0, ParameterDirection.Input, PaymentType),
                new MSSQL.Parameter("OperatorType", SqlDbType.Int, 0, ParameterDirection.Input, OperatorType)
                );

            return CallResult;
        }

        public static int P_Site_ShopOrderOut(long CreateShopID, long CreateOperID, long SalesID, string Remark, ref string Retrun)
        {
            DataSet ds = null;

            return P_Site_ShopOrderOut(ref ds, CreateShopID, CreateOperID, SalesID, Remark, ref Retrun);
        }

        public static int P_Site_ShopOrderOut(ref DataSet ds, long CreateShopID, long CreateOperID, long SalesID, string Remark, ref string Retrun)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_ShopOrderOut", ref ds, ref Outputs,
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("SalesID", SqlDbType.BigInt, 0, ParameterDirection.Input, SalesID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("Retrun", SqlDbType.VarChar, 254, ParameterDirection.Output, Retrun)
                );

            try
            {
                Retrun = System.Convert.ToString(Outputs["Retrun"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Site_AddDepotOut_Master(long CreateShopID, long CreateOperID, int OutType, long InvoiceID, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Site_AddDepotOut_Master(ref ds, CreateShopID, CreateOperID, OutType, InvoiceID, Remark, ref NewID);
        }

        public static int P_Site_AddDepotOut_Master(ref DataSet ds, long CreateShopID, long CreateOperID, int OutType, long InvoiceID, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_AddDepotOut_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("OutType", SqlDbType.Int, 0, ParameterDirection.Input, OutType),
                new MSSQL.Parameter("InvoiceID", SqlDbType.BigInt, 0, ParameterDirection.Input, InvoiceID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Site_CheckDepotOut(long OutID, long VerfyOperID, ref string RetrunDescription)
        {
            DataSet ds = null;

            return P_Site_CheckDepotOut(ref ds, OutID, VerfyOperID, ref RetrunDescription);
        }

        public static int P_Site_CheckDepotOut(ref DataSet ds, long OutID, long VerfyOperID, ref string RetrunDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_CheckDepotOut", ref ds, ref Outputs,
                new MSSQL.Parameter("OutID", SqlDbType.BigInt, 0, ParameterDirection.Input, OutID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID),
                new MSSQL.Parameter("RetrunDescription", SqlDbType.VarChar, 50, ParameterDirection.Output, RetrunDescription)
                );

            try
            {
                RetrunDescription = System.Convert.ToString(Outputs["RetrunDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Site_AddShipment_Master(string CustomerName, string Address, string Telephone, string Mobile, string Email, string PostCode, string CarriageCompany, string CarriageNo, string CarriageTel, string CarriageMoney, long CreateOperID, long InvoiceID, long CreateShopID, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Site_AddShipment_Master(ref ds, CustomerName, Address, Telephone, Mobile, Email, PostCode, CarriageCompany, CarriageNo, CarriageTel, CarriageMoney, CreateOperID, InvoiceID, CreateShopID, Remark, ref NewID);
        }

        public static int P_Site_AddShipment_Master(ref DataSet ds, string CustomerName, string Address, string Telephone, string Mobile, string Email, string PostCode, string CarriageCompany, string CarriageNo, string CarriageTel, string CarriageMoney, long CreateOperID, long InvoiceID, long CreateShopID, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_AddShipment_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerName),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 0, ParameterDirection.Input, Address),
                new MSSQL.Parameter("Telephone", SqlDbType.VarChar, 0, ParameterDirection.Input, Telephone),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 0, ParameterDirection.Input, Mobile),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 0, ParameterDirection.Input, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 0, ParameterDirection.Input, PostCode),
                new MSSQL.Parameter("CarriageCompany", SqlDbType.VarChar, 0, ParameterDirection.Input, CarriageCompany),
                new MSSQL.Parameter("CarriageNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CarriageNo),
                new MSSQL.Parameter("CarriageTel", SqlDbType.VarChar, 0, ParameterDirection.Input, CarriageTel),
                new MSSQL.Parameter("CarriageMoney", SqlDbType.VarChar, 0, ParameterDirection.Input, CarriageMoney),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("InvoiceID", SqlDbType.BigInt, 0, ParameterDirection.Input, InvoiceID),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_PVList()
        {
            DataSet ds = null;

            return P_PVList(ref ds);
        }

        public static int P_PVList(ref DataSet ds)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_PVList", ref ds, ref Outputs);

            return CallResult;
        }

        public static int P_Shop_AddDepotIN_Master(long InvoiceID, long CreateOperID, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddDepotIN_Master(ref ds, InvoiceID, CreateOperID, Remark, ref NewID);
        }

        public static int P_Shop_AddDepotIN_Master(ref DataSet ds, long InvoiceID, long CreateOperID, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddDepotIN_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("InvoiceID", SqlDbType.BigInt, 0, ParameterDirection.Input, InvoiceID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_GetInInvoiceNO(long ShopID)
        {
            DataSet ds = null;

            return P_Shop_GetInInvoiceNO(ref ds, ShopID);
        }

        public static int P_Shop_GetInInvoiceNO(ref DataSet ds, long ShopID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_GetInInvoiceNO", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID)
                );

            return CallResult;
        }

        public static int P_Shop_GetAllocateInvoiceNOByID(long ID, ref string InvoiceNO)
        {
            DataSet ds = null;

            return P_Shop_GetAllocateInvoiceNOByID(ref ds, ID, ref InvoiceNO);
        }

        public static int P_Shop_GetAllocateInvoiceNOByID(ref DataSet ds, long ID, ref string InvoiceNO)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_GetAllocateInvoiceNOByID", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("InvoiceNO", SqlDbType.VarChar, 50, ParameterDirection.Output, InvoiceNO)
                );

            try
            {
                InvoiceNO = System.Convert.ToString(Outputs["InvoiceNO"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_AddGoodType(string Level, string TypeName, short TypeKind, short TypeStatus, string Introduce, string Remark, long SiteID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_Shop_AddGoodType(ref ds, Level, TypeName, TypeKind, TypeStatus, Introduce, Remark, SiteID, ref ReturnDescription);
        }

        public static int P_Shop_AddGoodType(ref DataSet ds, string Level, string TypeName, short TypeKind, short TypeStatus, string Introduce, string Remark, long SiteID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddGoodType", ref ds, ref Outputs,
                new MSSQL.Parameter("Level", SqlDbType.VarChar, 0, ParameterDirection.Input, Level),
                new MSSQL.Parameter("TypeName", SqlDbType.VarChar, 0, ParameterDirection.Input, TypeName),
                new MSSQL.Parameter("TypeKind", SqlDbType.TinyInt, 0, ParameterDirection.Input, TypeKind),
                new MSSQL.Parameter("TypeStatus", SqlDbType.TinyInt, 0, ParameterDirection.Input, TypeStatus),
                new MSSQL.Parameter("Introduce", SqlDbType.VarChar, 0, ParameterDirection.Input, Introduce),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("SiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, SiteID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 30, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_AddRequestGood_Master(long SourceShopID, long TargetShopID, long CreateShopID, long CreateOperID, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddRequestGood_Master(ref ds, SourceShopID, TargetShopID, CreateShopID, CreateOperID, Remark, ref NewID);
        }

        public static int P_Shop_AddRequestGood_Master(ref DataSet ds, long SourceShopID, long TargetShopID, long CreateShopID, long CreateOperID, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddRequestGood_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("SourceShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, SourceShopID),
                new MSSQL.Parameter("TargetShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, TargetShopID),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Site_SalesGoodDetail(string SaleStart, string SaleEnd, long ShopIDs, string GoodNames, string GoodNos)
        {
            DataSet ds = null;

            return P_Site_SalesGoodDetail(ref ds, SaleStart, SaleEnd, ShopIDs, GoodNames, GoodNos);
        }

        public static int P_Site_SalesGoodDetail(ref DataSet ds, string SaleStart, string SaleEnd, long ShopIDs, string GoodNames, string GoodNos)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_SalesGoodDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("SaleStart", SqlDbType.VarChar, 0, ParameterDirection.Input, SaleStart),
                new MSSQL.Parameter("SaleEnd", SqlDbType.VarChar, 0, ParameterDirection.Input, SaleEnd),
                new MSSQL.Parameter("ShopIDs", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopIDs),
                new MSSQL.Parameter("GoodNames", SqlDbType.VarChar, 0, ParameterDirection.Input, GoodNames),
                new MSSQL.Parameter("GoodNos", SqlDbType.VarChar, 0, ParameterDirection.Input, GoodNos)
                );

            return CallResult;
        }

        public static int P_Shop_AddProcurement_Detail(long InID, long GoodID, int Amount, double ActualPrice)
        {
            DataSet ds = null;

            return P_Shop_AddProcurement_Detail(ref ds, InID, GoodID, Amount, ActualPrice);
        }

        public static int P_Shop_AddProcurement_Detail(ref DataSet ds, long InID, long GoodID, int Amount, double ActualPrice)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddProcurement_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("InID", SqlDbType.BigInt, 0, ParameterDirection.Input, InID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualPrice", SqlDbType.Float, 0, ParameterDirection.Input, ActualPrice)
                );

            return CallResult;
        }

        public static int P_Shop_EditRequestGood_Detail(long ID, long RequestGoodID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditRequestGood_Detail(ref ds, ID, RequestGoodID, GoodID, Amount);
        }

        public static int P_Shop_EditRequestGood_Detail(ref DataSet ds, long ID, long RequestGoodID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditRequestGood_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("RequestGoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, RequestGoodID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_Site_SalesGoodDetail2(string SaleStart, string SaleEnd, long ShopIDs, long GoodIDs)
        {
            DataSet ds = null;

            return P_Site_SalesGoodDetail2(ref ds, SaleStart, SaleEnd, ShopIDs, GoodIDs);
        }

        public static int P_Site_SalesGoodDetail2(ref DataSet ds, string SaleStart, string SaleEnd, long ShopIDs, long GoodIDs)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Site_SalesGoodDetail2", ref ds, ref Outputs,
                new MSSQL.Parameter("SaleStart", SqlDbType.VarChar, 0, ParameterDirection.Input, SaleStart),
                new MSSQL.Parameter("SaleEnd", SqlDbType.VarChar, 0, ParameterDirection.Input, SaleEnd),
                new MSSQL.Parameter("ShopIDs", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopIDs),
                new MSSQL.Parameter("GoodIDs", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodIDs)
                );

            return CallResult;
        }

        public static int P_Shop_DelRequestGood_Detail(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelRequestGood_Detail(ref ds, ID);
        }

        public static int P_Shop_DelRequestGood_Detail(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelRequestGood_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_AddRequestGood_Detail(long ID, long GoodID, int Amount, double ActualPrice)
        {
            DataSet ds = null;

            return P_Shop_AddRequestGood_Detail(ref ds, ID, GoodID, Amount, ActualPrice);
        }

        public static int P_Shop_AddRequestGood_Detail(ref DataSet ds, long ID, long GoodID, int Amount, double ActualPrice)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddRequestGood_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualPrice", SqlDbType.Float, 0, ParameterDirection.Input, ActualPrice)
                );

            return CallResult;
        }

        public static int P_GetScoreForCustomer2(long CustomerID, ref long L, ref long R, ref long L_CurrentMonth, ref long R_CurrentMonth, ref long L_CurrentWeek, ref long R_CurrentWeek, ref double L_PV, ref double R_PV)
        {
            DataSet ds = null;

            return P_GetScoreForCustomer2(ref ds, CustomerID, ref L, ref R, ref L_CurrentMonth, ref R_CurrentMonth, ref L_CurrentWeek, ref R_CurrentWeek, ref L_PV, ref R_PV);
        }

        public static int P_GetScoreForCustomer2(ref DataSet ds, long CustomerID, ref long L, ref long R, ref long L_CurrentMonth, ref long R_CurrentMonth, ref long L_CurrentWeek, ref long R_CurrentWeek, ref double L_PV, ref double R_PV)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetScoreForCustomer2", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("L", SqlDbType.BigInt, 8, ParameterDirection.Output, L),
                new MSSQL.Parameter("R", SqlDbType.BigInt, 8, ParameterDirection.Output, R),
                new MSSQL.Parameter("L_CurrentMonth", SqlDbType.BigInt, 8, ParameterDirection.Output, L_CurrentMonth),
                new MSSQL.Parameter("R_CurrentMonth", SqlDbType.BigInt, 8, ParameterDirection.Output, R_CurrentMonth),
                new MSSQL.Parameter("L_CurrentWeek", SqlDbType.BigInt, 8, ParameterDirection.Output, L_CurrentWeek),
                new MSSQL.Parameter("R_CurrentWeek", SqlDbType.BigInt, 8, ParameterDirection.Output, R_CurrentWeek),
                new MSSQL.Parameter("L_PV", SqlDbType.Money, 8, ParameterDirection.Output, L_PV),
                new MSSQL.Parameter("R_PV", SqlDbType.Money, 8, ParameterDirection.Output, R_PV)
                );

            try
            {
                L = System.Convert.ToInt64(Outputs["L"]);
            }
            catch { }

            try
            {
                R = System.Convert.ToInt64(Outputs["R"]);
            }
            catch { }

            try
            {
                L_CurrentMonth = System.Convert.ToInt64(Outputs["L_CurrentMonth"]);
            }
            catch { }

            try
            {
                R_CurrentMonth = System.Convert.ToInt64(Outputs["R_CurrentMonth"]);
            }
            catch { }

            try
            {
                L_CurrentWeek = System.Convert.ToInt64(Outputs["L_CurrentWeek"]);
            }
            catch { }

            try
            {
                R_CurrentWeek = System.Convert.ToInt64(Outputs["R_CurrentWeek"]);
            }
            catch { }

            try
            {
                L_PV = System.Convert.ToDouble(Outputs["L_PV"]);
            }
            catch { }

            try
            {
                R_PV = System.Convert.ToDouble(Outputs["R_PV"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_AddProcurement_Master(long SupplierID, long TargetShopID, long CreateOperID, string Remark, ref long NowID)
        {
            DataSet ds = null;

            return P_Shop_AddProcurement_Master(ref ds, SupplierID, TargetShopID, CreateOperID, Remark, ref NowID);
        }

        public static int P_Shop_AddProcurement_Master(ref DataSet ds, long SupplierID, long TargetShopID, long CreateOperID, string Remark, ref long NowID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddProcurement_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("SupplierID", SqlDbType.BigInt, 0, ParameterDirection.Input, SupplierID),
                new MSSQL.Parameter("TargetShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, TargetShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NowID", SqlDbType.BigInt, 8, ParameterDirection.Output, NowID)
                );

            try
            {
                NowID = System.Convert.ToInt64(Outputs["NowID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_EditProcurement_Detail(long ID, long InID, long GoodID, int Amount, int ActualAmount)
        {
            DataSet ds = null;

            return P_Shop_EditProcurement_Detail(ref ds, ID, InID, GoodID, Amount, ActualAmount);
        }

        public static int P_Shop_EditProcurement_Detail(ref DataSet ds, long ID, long InID, long GoodID, int Amount, int ActualAmount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditProcurement_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("InID", SqlDbType.BigInt, 0, ParameterDirection.Input, InID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualAmount", SqlDbType.Int, 0, ParameterDirection.Input, ActualAmount)
                );

            return CallResult;
        }

        public static int P_Shop_CheckDepotOut(long OutID, long VerfyOperID, ref string RetrunDescription)
        {
            DataSet ds = null;

            return P_Shop_CheckDepotOut(ref ds, OutID, VerfyOperID, ref RetrunDescription);
        }

        public static int P_Shop_CheckDepotOut(ref DataSet ds, long OutID, long VerfyOperID, ref string RetrunDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckDepotOut", ref ds, ref Outputs,
                new MSSQL.Parameter("OutID", SqlDbType.BigInt, 0, ParameterDirection.Input, OutID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID),
                new MSSQL.Parameter("RetrunDescription", SqlDbType.VarChar, 50, ParameterDirection.Output, RetrunDescription)
                );

            try
            {
                RetrunDescription = System.Convert.ToString(Outputs["RetrunDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetCustomerVirtualDetail(long CustomerID, int Year, int Month)
        {
            DataSet ds = null;

            return P_GetCustomerVirtualDetail(ref ds, CustomerID, Year, Month);
        }

        public static int P_GetCustomerVirtualDetail(ref DataSet ds, long CustomerID, int Year, int Month)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerVirtualDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Year", SqlDbType.Int, 0, ParameterDirection.Input, Year),
                new MSSQL.Parameter("Month", SqlDbType.Int, 0, ParameterDirection.Input, Month)
                );

            return CallResult;
        }

        public static int P_CustomerDistill2(DateTime StartDate, DateTime EndDate, long ShopID, long CustomerID, double Money, string BankName, string BankCardNumber, string Memo, double DistillFormalitiesFeesScale, long OperatorID, int PaymentType, long PaymentFilesID, int Type, ref int ResultValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerDistill2(ref ds, StartDate, EndDate, ShopID, CustomerID, Money, BankName, BankCardNumber, Memo, DistillFormalitiesFeesScale, OperatorID, PaymentType, PaymentFilesID, Type, ref ResultValue, ref ReturnDescription);
        }

        public static int P_CustomerDistill2(ref DataSet ds, DateTime StartDate, DateTime EndDate, long ShopID, long CustomerID, double Money, string BankName, string BankCardNumber, string Memo, double DistillFormalitiesFeesScale, long OperatorID, int PaymentType, long PaymentFilesID, int Type, ref int ResultValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerDistill2", ref ds, ref Outputs,
                new MSSQL.Parameter("StartDate", SqlDbType.DateTime, 0, ParameterDirection.Input, StartDate),
                new MSSQL.Parameter("EndDate", SqlDbType.DateTime, 0, ParameterDirection.Input, EndDate),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("BankName", SqlDbType.VarChar, 0, ParameterDirection.Input, BankName),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNumber),
                new MSSQL.Parameter("Memo", SqlDbType.VarChar, 0, ParameterDirection.Input, Memo),
                new MSSQL.Parameter("DistillFormalitiesFeesScale", SqlDbType.Money, 0, ParameterDirection.Input, DistillFormalitiesFeesScale),
                new MSSQL.Parameter("OperatorID", SqlDbType.BigInt, 0, ParameterDirection.Input, OperatorID),
                new MSSQL.Parameter("PaymentType", SqlDbType.Int, 0, ParameterDirection.Input, PaymentType),
                new MSSQL.Parameter("PaymentFilesID", SqlDbType.BigInt, 0, ParameterDirection.Input, PaymentFilesID),
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("ResultValue", SqlDbType.Int, 4, ParameterDirection.Output, ResultValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ResultValue = System.Convert.ToInt32(Outputs["ResultValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetCustomerBvDetail(long CustomerID, int Year, int Month)
        {
            DataSet ds = null;

            return P_GetCustomerBvDetail(ref ds, CustomerID, Year, Month);
        }

        public static int P_GetCustomerBvDetail(ref DataSet ds, long CustomerID, int Year, int Month)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerBvDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Year", SqlDbType.Int, 0, ParameterDirection.Input, Year),
                new MSSQL.Parameter("Month", SqlDbType.Int, 0, ParameterDirection.Input, Month)
                );

            return CallResult;
        }

        public static int P_GetScoreByWeek()
        {
            DataSet ds = null;

            return P_GetScoreByWeek(ref ds);
        }

        public static int P_GetScoreByWeek(ref DataSet ds)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetScoreByWeek", ref ds, ref Outputs);

            return CallResult;
        }

        public static int P_Shop_AddInventory_Detail(long InventoryID, long GoodID, int Amount, double ActualPrice)
        {
            DataSet ds = null;

            return P_Shop_AddInventory_Detail(ref ds, InventoryID, GoodID, Amount, ActualPrice);
        }

        public static int P_Shop_AddInventory_Detail(ref DataSet ds, long InventoryID, long GoodID, int Amount, double ActualPrice)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddInventory_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("InventoryID", SqlDbType.BigInt, 0, ParameterDirection.Input, InventoryID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualPrice", SqlDbType.Float, 0, ParameterDirection.Input, ActualPrice)
                );

            return CallResult;
        }

        public static int P_Shop_AddInventory_Master(long CreateShopID, long CreateOperID, int InventoryType, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddInventory_Master(ref ds, CreateShopID, CreateOperID, InventoryType, Remark, ref NewID);
        }

        public static int P_Shop_AddInventory_Master(ref DataSet ds, long CreateShopID, long CreateOperID, int InventoryType, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddInventory_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("InventoryType", SqlDbType.Int, 0, ParameterDirection.Input, InventoryType),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_DelInventory_Detail(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelInventory_Detail(ref ds, ID);
        }

        public static int P_Shop_DelInventory_Detail(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelInventory_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_DelInventoryMaster(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelInventoryMaster(ref ds, ID);
        }

        public static int P_Shop_DelInventoryMaster(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelInventoryMaster", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_EditInventory_Detail(long ID, long InventoryID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditInventory_Detail(ref ds, ID, InventoryID, GoodID, Amount);
        }

        public static int P_Shop_EditInventory_Detail(ref DataSet ds, long ID, long InventoryID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditInventory_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("InventoryID", SqlDbType.BigInt, 0, ParameterDirection.Input, InventoryID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_Shop_DelProcurementDetail(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelProcurementDetail(ref ds, ID);
        }

        public static int P_Shop_DelProcurementDetail(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelProcurementDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_AddAllocate_Master(long SourceShopID, long TargetShopID, long CreateOperID, long InvoiceID, DateTime CreateDate, string Remark, long CreateShopID, short AllocateType, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddAllocate_Master(ref ds, SourceShopID, TargetShopID, CreateOperID, InvoiceID, CreateDate, Remark, CreateShopID, AllocateType, ref NewID);
        }

        public static int P_Shop_AddAllocate_Master(ref DataSet ds, long SourceShopID, long TargetShopID, long CreateOperID, long InvoiceID, DateTime CreateDate, string Remark, long CreateShopID, short AllocateType, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddAllocate_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("SourceShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, SourceShopID),
                new MSSQL.Parameter("TargetShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, TargetShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("InvoiceID", SqlDbType.BigInt, 0, ParameterDirection.Input, InvoiceID),
                new MSSQL.Parameter("CreateDate", SqlDbType.DateTime, 0, ParameterDirection.Input, CreateDate),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("AllocateType", SqlDbType.TinyInt, 0, ParameterDirection.Input, AllocateType),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_GetAllocateInvoiceNO(long ShopID)
        {
            DataSet ds = null;

            return P_Shop_GetAllocateInvoiceNO(ref ds, ShopID);
        }

        public static int P_Shop_GetAllocateInvoiceNO(ref DataSet ds, long ShopID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_GetAllocateInvoiceNO", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID)
                );

            return CallResult;
        }

        public static int P_Shop_AddBackGood_Detail(long BackGoodID, long GoodID, int Amount, double ActualPrice)
        {
            DataSet ds = null;

            return P_Shop_AddBackGood_Detail(ref ds, BackGoodID, GoodID, Amount, ActualPrice);
        }

        public static int P_Shop_AddBackGood_Detail(ref DataSet ds, long BackGoodID, long GoodID, int Amount, double ActualPrice)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddBackGood_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("BackGoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, BackGoodID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualPrice", SqlDbType.Float, 0, ParameterDirection.Input, ActualPrice)
                );

            return CallResult;
        }

        public static int P_CustomerAddMoneyManual(long ShopID, long CustomerID, double Money, string Memo, long OperatorID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerAddMoneyManual(ref ds, ShopID, CustomerID, Money, Memo, OperatorID, ref ReturnDescription);
        }

        public static int P_CustomerAddMoneyManual(ref DataSet ds, long ShopID, long CustomerID, double Money, string Memo, long OperatorID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerAddMoneyManual", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("Memo", SqlDbType.VarChar, 0, ParameterDirection.Input, Memo),
                new MSSQL.Parameter("OperatorID", SqlDbType.BigInt, 0, ParameterDirection.Input, OperatorID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_AddBackGood_Master(long CustomerID, long TargetShopID, long SourceShopID, long CreateOperID, long CreateShopID, short BackType, string ReturnSeason, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddBackGood_Master(ref ds, CustomerID, TargetShopID, SourceShopID, CreateOperID, CreateShopID, BackType, ReturnSeason, ref NewID);
        }

        public static int P_Shop_AddBackGood_Master(ref DataSet ds, long CustomerID, long TargetShopID, long SourceShopID, long CreateOperID, long CreateShopID, short BackType, string ReturnSeason, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddBackGood_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("TargetShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, TargetShopID),
                new MSSQL.Parameter("SourceShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, SourceShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("BackType", SqlDbType.TinyInt, 0, ParameterDirection.Input, BackType),
                new MSSQL.Parameter("ReturnSeason", SqlDbType.VarChar, 0, ParameterDirection.Input, ReturnSeason),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_EditBackGood_Detail(long ID, long BackGoodID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditBackGood_Detail(ref ds, ID, BackGoodID, GoodID, Amount);
        }

        public static int P_Shop_EditBackGood_Detail(ref DataSet ds, long ID, long BackGoodID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditBackGood_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("BackGoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, BackGoodID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_CustomerAddMoney(long ShopID, long CustomerID, double Money, double FormalitiesFees, string PayNumber, string PayBank, string Memo, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerAddMoney(ref ds, ShopID, CustomerID, Money, FormalitiesFees, PayNumber, PayBank, Memo, ref ReturnDescription);
        }

        public static int P_CustomerAddMoney(ref DataSet ds, long ShopID, long CustomerID, double Money, double FormalitiesFees, string PayNumber, string PayBank, string Memo, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerAddMoney", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("FormalitiesFees", SqlDbType.Money, 0, ParameterDirection.Input, FormalitiesFees),
                new MSSQL.Parameter("PayNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, PayNumber),
                new MSSQL.Parameter("PayBank", SqlDbType.VarChar, 0, ParameterDirection.Input, PayBank),
                new MSSQL.Parameter("Memo", SqlDbType.VarChar, 0, ParameterDirection.Input, Memo),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_AddDepotOut_Master(long CreateShopID, long CreateOperID, int OutType, long InvoiceID, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddDepotOut_Master(ref ds, CreateShopID, CreateOperID, OutType, InvoiceID, Remark, ref NewID);
        }

        public static int P_Shop_AddDepotOut_Master(ref DataSet ds, long CreateShopID, long CreateOperID, int OutType, long InvoiceID, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddDepotOut_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("OutType", SqlDbType.Int, 0, ParameterDirection.Input, OutType),
                new MSSQL.Parameter("InvoiceID", SqlDbType.BigInt, 0, ParameterDirection.Input, InvoiceID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetScoreForCustomer(long CustomerID, ref long L, ref long R, ref long L_CurrentMonth, ref long R_CurrentMonth, ref long L_CurrentDay, ref long R_CurrentDay, ref int L_Residual, ref int R_Residual)
        {
            DataSet ds = null;

            return P_GetScoreForCustomer(ref ds, CustomerID, ref L, ref R, ref L_CurrentMonth, ref R_CurrentMonth, ref L_CurrentDay, ref R_CurrentDay, ref L_Residual, ref R_Residual);
        }

        public static int P_GetScoreForCustomer(ref DataSet ds, long CustomerID, ref long L, ref long R, ref long L_CurrentMonth, ref long R_CurrentMonth, ref long L_CurrentDay, ref long R_CurrentDay, ref int L_Residual, ref int R_Residual)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetScoreForCustomer", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("L", SqlDbType.BigInt, 8, ParameterDirection.Output, L),
                new MSSQL.Parameter("R", SqlDbType.BigInt, 8, ParameterDirection.Output, R),
                new MSSQL.Parameter("L_CurrentMonth", SqlDbType.BigInt, 8, ParameterDirection.Output, L_CurrentMonth),
                new MSSQL.Parameter("R_CurrentMonth", SqlDbType.BigInt, 8, ParameterDirection.Output, R_CurrentMonth),
                new MSSQL.Parameter("L_CurrentDay", SqlDbType.BigInt, 8, ParameterDirection.Output, L_CurrentDay),
                new MSSQL.Parameter("R_CurrentDay", SqlDbType.BigInt, 8, ParameterDirection.Output, R_CurrentDay),
                new MSSQL.Parameter("L_Residual", SqlDbType.Int, 4, ParameterDirection.Output, L_Residual),
                new MSSQL.Parameter("R_Residual", SqlDbType.Int, 4, ParameterDirection.Output, R_Residual)
                );

            try
            {
                L = System.Convert.ToInt64(Outputs["L"]);
            }
            catch { }

            try
            {
                R = System.Convert.ToInt64(Outputs["R"]);
            }
            catch { }

            try
            {
                L_CurrentMonth = System.Convert.ToInt64(Outputs["L_CurrentMonth"]);
            }
            catch { }

            try
            {
                R_CurrentMonth = System.Convert.ToInt64(Outputs["R_CurrentMonth"]);
            }
            catch { }

            try
            {
                L_CurrentDay = System.Convert.ToInt64(Outputs["L_CurrentDay"]);
            }
            catch { }

            try
            {
                R_CurrentDay = System.Convert.ToInt64(Outputs["R_CurrentDay"]);
            }
            catch { }

            try
            {
                L_Residual = System.Convert.ToInt32(Outputs["L_Residual"]);
            }
            catch { }

            try
            {
                R_Residual = System.Convert.ToInt32(Outputs["R_Residual"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_GetOutInvoiceNOByID(long ID, ref string InvoiceNO)
        {
            DataSet ds = null;

            return P_Shop_GetOutInvoiceNOByID(ref ds, ID, ref InvoiceNO);
        }

        public static int P_Shop_GetOutInvoiceNOByID(ref DataSet ds, long ID, ref string InvoiceNO)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_GetOutInvoiceNOByID", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("InvoiceNO", SqlDbType.VarChar, 50, ParameterDirection.Output, InvoiceNO)
                );

            try
            {
                InvoiceNO = System.Convert.ToString(Outputs["InvoiceNO"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_GetOutInvoiceNO(int Type, long ShopID)
        {
            DataSet ds = null;

            return P_Shop_GetOutInvoiceNO(ref ds, Type, ShopID);
        }

        public static int P_Shop_GetOutInvoiceNO(ref DataSet ds, int Type, long ShopID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_GetOutInvoiceNO", ref ds, ref Outputs,
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID)
                );

            return CallResult;
        }

        public static int P_Shop_AddLoss_Detail(long LossID, long GoodID, int Amount, double ActualPrice)
        {
            DataSet ds = null;

            return P_Shop_AddLoss_Detail(ref ds, LossID, GoodID, Amount, ActualPrice);
        }

        public static int P_Shop_AddLoss_Detail(ref DataSet ds, long LossID, long GoodID, int Amount, double ActualPrice)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddLoss_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("LossID", SqlDbType.BigInt, 0, ParameterDirection.Input, LossID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualPrice", SqlDbType.Float, 0, ParameterDirection.Input, ActualPrice)
                );

            return CallResult;
        }

        public static int P_GetCustomerAccountDetail2(long CustomerID, int Year, int Month)
        {
            DataSet ds = null;

            return P_GetCustomerAccountDetail2(ref ds, CustomerID, Year, Month);
        }

        public static int P_GetCustomerAccountDetail2(ref DataSet ds, long CustomerID, int Year, int Month)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerAccountDetail2", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Year", SqlDbType.Int, 0, ParameterDirection.Input, Year),
                new MSSQL.Parameter("Month", SqlDbType.Int, 0, ParameterDirection.Input, Month)
                );

            return CallResult;
        }

        public static int P_Shop_AddLoss_Master(long TargetShopID, long SourceShopID, long CreateOperID, long CreateShopID, short LossType, string Remark, ref long NewID)
        {
            DataSet ds = null;

            return P_Shop_AddLoss_Master(ref ds, TargetShopID, SourceShopID, CreateOperID, CreateShopID, LossType, Remark, ref NewID);
        }

        public static int P_Shop_AddLoss_Master(ref DataSet ds, long TargetShopID, long SourceShopID, long CreateOperID, long CreateShopID, short LossType, string Remark, ref long NewID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddLoss_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("TargetShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, TargetShopID),
                new MSSQL.Parameter("SourceShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, SourceShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("LossType", SqlDbType.TinyInt, 0, ParameterDirection.Input, LossType),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NewID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewID)
                );

            try
            {
                NewID = System.Convert.ToInt64(Outputs["NewID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_EditLoss_Detail(long ID, long LossID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditLoss_Detail(ref ds, ID, LossID, GoodID, Amount);
        }

        public static int P_Shop_EditLoss_Detail(ref DataSet ds, long ID, long LossID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditLoss_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("LossID", SqlDbType.BigInt, 0, ParameterDirection.Input, LossID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_GetCustomerAccountDetail(long CustomerID, int Year, int Month)
        {
            DataSet ds = null;

            return P_GetCustomerAccountDetail(ref ds, CustomerID, Year, Month);
        }

        public static int P_GetCustomerAccountDetail(ref DataSet ds, long CustomerID, int Year, int Month)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerAccountDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Year", SqlDbType.Int, 0, ParameterDirection.Input, Year),
                new MSSQL.Parameter("Month", SqlDbType.Int, 0, ParameterDirection.Input, Month)
                );

            return CallResult;
        }

        public static int P_EarningToVirtual(long CustomerID, string ToUserName, double Money, string Remark, int Type, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_EarningToVirtual(ref ds, CustomerID, ToUserName, Money, Remark, Type, ref ReturnDescription);
        }

        public static int P_EarningToVirtual(ref DataSet ds, long CustomerID, string ToUserName, double Money, string Remark, int Type, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_EarningToVirtual", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("ToUserName", SqlDbType.VarChar, 0, ParameterDirection.Input, ToUserName),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_ReBuy(long SurrogateID, long CustomerID, int CustomerTypeID, ref int ReturnValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_ReBuy(ref ds, SurrogateID, CustomerID, CustomerTypeID, ref ReturnValue, ref ReturnDescription);
        }

        public static int P_ReBuy(ref DataSet ds, long SurrogateID, long CustomerID, int CustomerTypeID, ref int ReturnValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_ReBuy", ref ds, ref Outputs,
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.Int, 0, ParameterDirection.Input, CustomerTypeID),
                new MSSQL.Parameter("ReturnValue", SqlDbType.Int, 4, ParameterDirection.Output, ReturnValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnValue = System.Convert.ToInt32(Outputs["ReturnValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_BuyForNets_2(long CustomerID, bool isOnce, bool isPresent, ref int ReturnValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_BuyForNets_2(ref ds, CustomerID, isOnce, isPresent, ref ReturnValue, ref ReturnDescription);
        }

        public static int P_BuyForNets_2(ref DataSet ds, long CustomerID, bool isOnce, bool isPresent, ref int ReturnValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_BuyForNets_2", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("isOnce", SqlDbType.Bit, 0, ParameterDirection.Input, isOnce),
                new MSSQL.Parameter("isPresent", SqlDbType.Bit, 0, ParameterDirection.Input, isPresent),
                new MSSQL.Parameter("ReturnValue", SqlDbType.Int, 4, ParameterDirection.Output, ReturnValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnValue = System.Convert.ToInt32(Outputs["ReturnValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetOneNodeFromNets2(ref long NetID, ref int LR)
        {
            DataSet ds = null;

            return P_GetOneNodeFromNets2(ref ds, ref NetID, ref LR);
        }

        public static int P_GetOneNodeFromNets2(ref DataSet ds, ref long NetID, ref int LR)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetOneNodeFromNets2", ref ds, ref Outputs,
                new MSSQL.Parameter("NetID", SqlDbType.BigInt, 8, ParameterDirection.Output, NetID),
                new MSSQL.Parameter("LR", SqlDbType.Int, 4, ParameterDirection.Output, LR)
                );

            try
            {
                NetID = System.Convert.ToInt64(Outputs["NetID"]);
            }
            catch { }

            try
            {
                LR = System.Convert.ToInt32(Outputs["LR"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_BuyForNets_2_All()
        {
            DataSet ds = null;

            return P_BuyForNets_2_All(ref ds);
        }

        public static int P_BuyForNets_2_All(ref DataSet ds)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_BuyForNets_2_All", ref ds, ref Outputs);

            return CallResult;
        }

        public static int P_BuyForNets_2_UserSelf(long CustomerID, ref int ReturnValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_BuyForNets_2_UserSelf(ref ds, CustomerID, ref ReturnValue, ref ReturnDescription);
        }

        public static int P_BuyForNets_2_UserSelf(ref DataSet ds, long CustomerID, ref int ReturnValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_BuyForNets_2_UserSelf", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("ReturnValue", SqlDbType.Int, 4, ParameterDirection.Output, ReturnValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnValue = System.Convert.ToInt32(Outputs["ReturnValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_RandomStr(ref string _RandomStrs)
        {
            DataSet ds = null;

            return P_RandomStr(ref ds, ref _RandomStrs);
        }

        public static int P_RandomStr(ref DataSet ds, ref string _RandomStrs)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_RandomStr", ref ds, ref Outputs,
                new MSSQL.Parameter("_RandomStrs", SqlDbType.VarChar, 6, ParameterDirection.Output, _RandomStrs)
                );

            try
            {
                _RandomStrs = System.Convert.ToString(Outputs["_RandomStrs"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_WriteSMS(long SiteID, long SMSID, string From, string To, string Content, ref long NewSMSID)
        {
            DataSet ds = null;

            return P_WriteSMS(ref ds, SiteID, SMSID, From, To, Content, ref NewSMSID);
        }

        public static int P_WriteSMS(ref DataSet ds, long SiteID, long SMSID, string From, string To, string Content, ref long NewSMSID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_WriteSMS", ref ds, ref Outputs,
                new MSSQL.Parameter("SiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, SiteID),
                new MSSQL.Parameter("SMSID", SqlDbType.BigInt, 0, ParameterDirection.Input, SMSID),
                new MSSQL.Parameter("From", SqlDbType.VarChar, 0, ParameterDirection.Input, From),
                new MSSQL.Parameter("To", SqlDbType.VarChar, 0, ParameterDirection.Input, To),
                new MSSQL.Parameter("Content", SqlDbType.VarChar, 0, ParameterDirection.Input, Content),
                new MSSQL.Parameter("NewSMSID", SqlDbType.BigInt, 8, ParameterDirection.Output, NewSMSID)
                );

            try
            {
                NewSMSID = System.Convert.ToInt64(Outputs["NewSMSID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_ActivationCustomer(long CustomerID, long SurrogateID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_ActivationCustomer(ref ds, CustomerID, SurrogateID, ref ReturnDescription);
        }

        public static int P_ActivationCustomer(ref DataSet ds, long CustomerID, long SurrogateID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_ActivationCustomer", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_UpdateView()
        {
            DataSet ds = null;

            return P_UpdateView(ref ds);
        }

        public static int P_UpdateView(ref DataSet ds)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_UpdateView", ref ds, ref Outputs);

            return CallResult;
        }

        public static int P_SetOptions(string Key, string Value)
        {
            DataSet ds = null;

            return P_SetOptions(ref ds, Key, Value);
        }

        public static int P_SetOptions(ref DataSet ds, string Key, string Value)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_SetOptions", ref ds, ref Outputs,
                new MSSQL.Parameter("Key", SqlDbType.VarChar, 0, ParameterDirection.Input, Key),
                new MSSQL.Parameter("Value", SqlDbType.VarChar, 0, ParameterDirection.Input, Value)
                );

            return CallResult;
        }

        public static int P_DelCustomer(long CustomerID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_DelCustomer(ref ds, CustomerID, ref ReturnDescription);
        }

        public static int P_DelCustomer(ref DataSet ds, long CustomerID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DelCustomer", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_SetGroupOfCompetences(int GroupID, string CompencesID, long ShopID)
        {
            DataSet ds = null;

            return P_SetGroupOfCompetences(ref ds, GroupID, CompencesID, ShopID);
        }

        public static int P_SetGroupOfCompetences(ref DataSet ds, int GroupID, string CompencesID, long ShopID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_SetGroupOfCompetences", ref ds, ref Outputs,
                new MSSQL.Parameter("GroupID", SqlDbType.Int, 0, ParameterDirection.Input, GroupID),
                new MSSQL.Parameter("CompencesID", SqlDbType.VarChar, 0, ParameterDirection.Input, CompencesID),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID)
                );

            return CallResult;
        }

        public static int P_GetSiteInformationByUrl(string Url, ref long ShopID, ref long ParentID, ref string ParentShopNO, ref string ParentShopName, ref long CustomerID, ref string CustomerNo, ref string CustomerName, ref short ShopTypeID, ref string ShopNo, ref string ShopName, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string BankName, ref string BankNameDetail, ref string BankCardNo, ref string BankCustName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref DateTime VerfyDate, ref long VerfyOperatorID, ref string VerfyCustomerNo, ref string VerfyCustomerName, ref short Status, ref string State, ref string Remark, ref string SiteTitle, ref string SiteURL, ref short SiteStatus, ref string SiteQQ, ref string SiteTelephone, ref string CopyRightInfo, ref string ICPCert, ref string EnterpriseWebSite, ref short EnterpriseWebStatus, ref double PV, ref double BV, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_GetSiteInformationByUrl(ref ds, Url, ref ShopID, ref ParentID, ref ParentShopNO, ref ParentShopName, ref CustomerID, ref CustomerNo, ref CustomerName, ref ShopTypeID, ref ShopNo, ref ShopName, ref Tel, ref Mobile, ref QQ, ref Email, ref PostCode, ref CityID, ref Province, ref City, ref Address, ref Fax, ref Other, ref BankName, ref BankNameDetail, ref BankCardNo, ref BankCustName, ref RegisterOperID, ref RegisterCustomerNO, ref RegisterCustomerName, ref RegisterDate, ref VerfyDate, ref VerfyOperatorID, ref VerfyCustomerNo, ref VerfyCustomerName, ref Status, ref State, ref Remark, ref SiteTitle, ref SiteURL, ref SiteStatus, ref SiteQQ, ref SiteTelephone, ref CopyRightInfo, ref ICPCert, ref EnterpriseWebSite, ref EnterpriseWebStatus, ref PV, ref BV, ref ReturnDescription);
        }

        public static int P_GetSiteInformationByUrl(ref DataSet ds, string Url, ref long ShopID, ref long ParentID, ref string ParentShopNO, ref string ParentShopName, ref long CustomerID, ref string CustomerNo, ref string CustomerName, ref short ShopTypeID, ref string ShopNo, ref string ShopName, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string BankName, ref string BankNameDetail, ref string BankCardNo, ref string BankCustName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref DateTime VerfyDate, ref long VerfyOperatorID, ref string VerfyCustomerNo, ref string VerfyCustomerName, ref short Status, ref string State, ref string Remark, ref string SiteTitle, ref string SiteURL, ref short SiteStatus, ref string SiteQQ, ref string SiteTelephone, ref string CopyRightInfo, ref string ICPCert, ref string EnterpriseWebSite, ref short EnterpriseWebStatus, ref double PV, ref double BV, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetSiteInformationByUrl", ref ds, ref Outputs,
                new MSSQL.Parameter("Url", SqlDbType.VarChar, 0, ParameterDirection.Input, Url),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 8, ParameterDirection.Output, ParentID),
                new MSSQL.Parameter("ParentShopNO", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentShopNO),
                new MSSQL.Parameter("ParentShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentShopName),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("CustomerNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerNo),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerName),
                new MSSQL.Parameter("ShopTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, ShopTypeID),
                new MSSQL.Parameter("ShopNo", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopNo),
                new MSSQL.Parameter("ShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopName),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 15, ParameterDirection.Output, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 15, ParameterDirection.Output, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 15, ParameterDirection.Output, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 50, ParameterDirection.Output, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 6, ParameterDirection.Output, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 4, ParameterDirection.Output, CityID),
                new MSSQL.Parameter("Province", SqlDbType.VarChar, 50, ParameterDirection.Output, Province),
                new MSSQL.Parameter("City", SqlDbType.VarChar, 50, ParameterDirection.Output, City),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 100, ParameterDirection.Output, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 15, ParameterDirection.Output, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 15, ParameterDirection.Output, Other),
                new MSSQL.Parameter("BankName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankName),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 50, ParameterDirection.Output, BankNameDetail),
                new MSSQL.Parameter("BankCardNo", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCardNo),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCustName),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterOperID),
                new MSSQL.Parameter("RegisterCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerNO),
                new MSSQL.Parameter("RegisterCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerName),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 8, ParameterDirection.Output, RegisterDate),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 8, ParameterDirection.Output, VerfyDate),
                new MSSQL.Parameter("VerfyOperatorID", SqlDbType.BigInt, 8, ParameterDirection.Output, VerfyOperatorID),
                new MSSQL.Parameter("VerfyCustomerNo", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerNo),
                new MSSQL.Parameter("VerfyCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerName),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 1, ParameterDirection.Output, Status),
                new MSSQL.Parameter("State", SqlDbType.VarChar, 50, ParameterDirection.Output, State),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 2000, ParameterDirection.Output, Remark),
                new MSSQL.Parameter("SiteTitle", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteTitle),
                new MSSQL.Parameter("SiteURL", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteURL),
                new MSSQL.Parameter("SiteStatus", SqlDbType.TinyInt, 1, ParameterDirection.Output, SiteStatus),
                new MSSQL.Parameter("SiteQQ", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteQQ),
                new MSSQL.Parameter("SiteTelephone", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteTelephone),
                new MSSQL.Parameter("CopyRightInfo", SqlDbType.VarChar, 50, ParameterDirection.Output, CopyRightInfo),
                new MSSQL.Parameter("ICPCert", SqlDbType.VarChar, 50, ParameterDirection.Output, ICPCert),
                new MSSQL.Parameter("EnterpriseWebSite", SqlDbType.VarChar, 50, ParameterDirection.Output, EnterpriseWebSite),
                new MSSQL.Parameter("EnterpriseWebStatus", SqlDbType.TinyInt, 1, ParameterDirection.Output, EnterpriseWebStatus),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 8, ParameterDirection.Output, BV),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                ParentID = System.Convert.ToInt64(Outputs["ParentID"]);
            }
            catch { }

            try
            {
                ParentShopNO = System.Convert.ToString(Outputs["ParentShopNO"]);
            }
            catch { }

            try
            {
                ParentShopName = System.Convert.ToString(Outputs["ParentShopName"]);
            }
            catch { }

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                CustomerNo = System.Convert.ToString(Outputs["CustomerNo"]);
            }
            catch { }

            try
            {
                CustomerName = System.Convert.ToString(Outputs["CustomerName"]);
            }
            catch { }

            try
            {
                ShopTypeID = System.Convert.ToInt16(Outputs["ShopTypeID"]);
            }
            catch { }

            try
            {
                ShopNo = System.Convert.ToString(Outputs["ShopNo"]);
            }
            catch { }

            try
            {
                ShopName = System.Convert.ToString(Outputs["ShopName"]);
            }
            catch { }

            try
            {
                Tel = System.Convert.ToString(Outputs["Tel"]);
            }
            catch { }

            try
            {
                Mobile = System.Convert.ToString(Outputs["Mobile"]);
            }
            catch { }

            try
            {
                QQ = System.Convert.ToString(Outputs["QQ"]);
            }
            catch { }

            try
            {
                Email = System.Convert.ToString(Outputs["Email"]);
            }
            catch { }

            try
            {
                PostCode = System.Convert.ToString(Outputs["PostCode"]);
            }
            catch { }

            try
            {
                CityID = System.Convert.ToInt32(Outputs["CityID"]);
            }
            catch { }

            try
            {
                Province = System.Convert.ToString(Outputs["Province"]);
            }
            catch { }

            try
            {
                City = System.Convert.ToString(Outputs["City"]);
            }
            catch { }

            try
            {
                Address = System.Convert.ToString(Outputs["Address"]);
            }
            catch { }

            try
            {
                Fax = System.Convert.ToString(Outputs["Fax"]);
            }
            catch { }

            try
            {
                Other = System.Convert.ToString(Outputs["Other"]);
            }
            catch { }

            try
            {
                BankName = System.Convert.ToString(Outputs["BankName"]);
            }
            catch { }

            try
            {
                BankNameDetail = System.Convert.ToString(Outputs["BankNameDetail"]);
            }
            catch { }

            try
            {
                BankCardNo = System.Convert.ToString(Outputs["BankCardNo"]);
            }
            catch { }

            try
            {
                BankCustName = System.Convert.ToString(Outputs["BankCustName"]);
            }
            catch { }

            try
            {
                RegisterOperID = System.Convert.ToInt64(Outputs["RegisterOperID"]);
            }
            catch { }

            try
            {
                RegisterCustomerNO = System.Convert.ToString(Outputs["RegisterCustomerNO"]);
            }
            catch { }

            try
            {
                RegisterCustomerName = System.Convert.ToString(Outputs["RegisterCustomerName"]);
            }
            catch { }

            try
            {
                RegisterDate = System.Convert.ToDateTime(Outputs["RegisterDate"]);
            }
            catch { }

            try
            {
                VerfyDate = System.Convert.ToDateTime(Outputs["VerfyDate"]);
            }
            catch { }

            try
            {
                VerfyOperatorID = System.Convert.ToInt64(Outputs["VerfyOperatorID"]);
            }
            catch { }

            try
            {
                VerfyCustomerNo = System.Convert.ToString(Outputs["VerfyCustomerNo"]);
            }
            catch { }

            try
            {
                VerfyCustomerName = System.Convert.ToString(Outputs["VerfyCustomerName"]);
            }
            catch { }

            try
            {
                Status = System.Convert.ToInt16(Outputs["Status"]);
            }
            catch { }

            try
            {
                State = System.Convert.ToString(Outputs["State"]);
            }
            catch { }

            try
            {
                Remark = System.Convert.ToString(Outputs["Remark"]);
            }
            catch { }

            try
            {
                SiteTitle = System.Convert.ToString(Outputs["SiteTitle"]);
            }
            catch { }

            try
            {
                SiteURL = System.Convert.ToString(Outputs["SiteURL"]);
            }
            catch { }

            try
            {
                SiteStatus = System.Convert.ToInt16(Outputs["SiteStatus"]);
            }
            catch { }

            try
            {
                SiteQQ = System.Convert.ToString(Outputs["SiteQQ"]);
            }
            catch { }

            try
            {
                SiteTelephone = System.Convert.ToString(Outputs["SiteTelephone"]);
            }
            catch { }

            try
            {
                CopyRightInfo = System.Convert.ToString(Outputs["CopyRightInfo"]);
            }
            catch { }

            try
            {
                ICPCert = System.Convert.ToString(Outputs["ICPCert"]);
            }
            catch { }

            try
            {
                EnterpriseWebSite = System.Convert.ToString(Outputs["EnterpriseWebSite"]);
            }
            catch { }

            try
            {
                EnterpriseWebStatus = System.Convert.ToInt16(Outputs["EnterpriseWebStatus"]);
            }
            catch { }

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                BV = System.Convert.ToDouble(Outputs["BV"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetSiteInformationByID(long ShopID, ref long ParentID, ref string ParentShopNO, ref string ParentShopName, ref long CustomerID, ref string CustomerNo, ref string CustomerName, ref short ShopTypeID, ref string ShopNo, ref string ShopName, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string BankName, ref string BankNameDetail, ref string BankCardNo, ref string BankCustName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref DateTime VerfyDate, ref long VerfyOperatorID, ref string VerfyCustomerNo, ref string VerfyCustomerName, ref short Status, ref string State, ref string Remark, ref string SiteTitle, ref string SiteURL, ref short SiteStatus, ref string SiteQQ, ref string SiteTelephone, ref string CopyRightInfo, ref string ICPCert, ref string EnterpriseWebSite, ref short EnterpriseWebStatus, ref double PV, ref double BV, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_GetSiteInformationByID(ref ds, ShopID, ref ParentID, ref ParentShopNO, ref ParentShopName, ref CustomerID, ref CustomerNo, ref CustomerName, ref ShopTypeID, ref ShopNo, ref ShopName, ref Tel, ref Mobile, ref QQ, ref Email, ref PostCode, ref CityID, ref Province, ref City, ref Address, ref Fax, ref Other, ref BankName, ref BankNameDetail, ref BankCardNo, ref BankCustName, ref RegisterOperID, ref RegisterCustomerNO, ref RegisterCustomerName, ref RegisterDate, ref VerfyDate, ref VerfyOperatorID, ref VerfyCustomerNo, ref VerfyCustomerName, ref Status, ref State, ref Remark, ref SiteTitle, ref SiteURL, ref SiteStatus, ref SiteQQ, ref SiteTelephone, ref CopyRightInfo, ref ICPCert, ref EnterpriseWebSite, ref EnterpriseWebStatus, ref PV, ref BV, ref ReturnDescription);
        }

        public static int P_GetSiteInformationByID(ref DataSet ds, long ShopID, ref long ParentID, ref string ParentShopNO, ref string ParentShopName, ref long CustomerID, ref string CustomerNo, ref string CustomerName, ref short ShopTypeID, ref string ShopNo, ref string ShopName, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string BankName, ref string BankNameDetail, ref string BankCardNo, ref string BankCustName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref DateTime VerfyDate, ref long VerfyOperatorID, ref string VerfyCustomerNo, ref string VerfyCustomerName, ref short Status, ref string State, ref string Remark, ref string SiteTitle, ref string SiteURL, ref short SiteStatus, ref string SiteQQ, ref string SiteTelephone, ref string CopyRightInfo, ref string ICPCert, ref string EnterpriseWebSite, ref short EnterpriseWebStatus, ref double PV, ref double BV, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetSiteInformationByID", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 8, ParameterDirection.Output, ParentID),
                new MSSQL.Parameter("ParentShopNO", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentShopNO),
                new MSSQL.Parameter("ParentShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentShopName),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("CustomerNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerNo),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerName),
                new MSSQL.Parameter("ShopTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, ShopTypeID),
                new MSSQL.Parameter("ShopNo", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopNo),
                new MSSQL.Parameter("ShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopName),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 15, ParameterDirection.Output, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 15, ParameterDirection.Output, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 15, ParameterDirection.Output, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 50, ParameterDirection.Output, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 6, ParameterDirection.Output, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 4, ParameterDirection.Output, CityID),
                new MSSQL.Parameter("Province", SqlDbType.VarChar, 50, ParameterDirection.Output, Province),
                new MSSQL.Parameter("City", SqlDbType.VarChar, 50, ParameterDirection.Output, City),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 100, ParameterDirection.Output, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 15, ParameterDirection.Output, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 15, ParameterDirection.Output, Other),
                new MSSQL.Parameter("BankName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankName),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 50, ParameterDirection.Output, BankNameDetail),
                new MSSQL.Parameter("BankCardNo", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCardNo),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCustName),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterOperID),
                new MSSQL.Parameter("RegisterCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerNO),
                new MSSQL.Parameter("RegisterCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerName),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 8, ParameterDirection.Output, RegisterDate),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 8, ParameterDirection.Output, VerfyDate),
                new MSSQL.Parameter("VerfyOperatorID", SqlDbType.BigInt, 8, ParameterDirection.Output, VerfyOperatorID),
                new MSSQL.Parameter("VerfyCustomerNo", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerNo),
                new MSSQL.Parameter("VerfyCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerName),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 1, ParameterDirection.Output, Status),
                new MSSQL.Parameter("State", SqlDbType.VarChar, 50, ParameterDirection.Output, State),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 2000, ParameterDirection.Output, Remark),
                new MSSQL.Parameter("SiteTitle", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteTitle),
                new MSSQL.Parameter("SiteURL", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteURL),
                new MSSQL.Parameter("SiteStatus", SqlDbType.TinyInt, 1, ParameterDirection.Output, SiteStatus),
                new MSSQL.Parameter("SiteQQ", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteQQ),
                new MSSQL.Parameter("SiteTelephone", SqlDbType.VarChar, 50, ParameterDirection.Output, SiteTelephone),
                new MSSQL.Parameter("CopyRightInfo", SqlDbType.VarChar, 50, ParameterDirection.Output, CopyRightInfo),
                new MSSQL.Parameter("ICPCert", SqlDbType.VarChar, 50, ParameterDirection.Output, ICPCert),
                new MSSQL.Parameter("EnterpriseWebSite", SqlDbType.VarChar, 50, ParameterDirection.Output, EnterpriseWebSite),
                new MSSQL.Parameter("EnterpriseWebStatus", SqlDbType.TinyInt, 1, ParameterDirection.Output, EnterpriseWebStatus),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 8, ParameterDirection.Output, BV),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ParentID = System.Convert.ToInt64(Outputs["ParentID"]);
            }
            catch { }

            try
            {
                ParentShopNO = System.Convert.ToString(Outputs["ParentShopNO"]);
            }
            catch { }

            try
            {
                ParentShopName = System.Convert.ToString(Outputs["ParentShopName"]);
            }
            catch { }

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                CustomerNo = System.Convert.ToString(Outputs["CustomerNo"]);
            }
            catch { }

            try
            {
                CustomerName = System.Convert.ToString(Outputs["CustomerName"]);
            }
            catch { }

            try
            {
                ShopTypeID = System.Convert.ToInt16(Outputs["ShopTypeID"]);
            }
            catch { }

            try
            {
                ShopNo = System.Convert.ToString(Outputs["ShopNo"]);
            }
            catch { }

            try
            {
                ShopName = System.Convert.ToString(Outputs["ShopName"]);
            }
            catch { }

            try
            {
                Tel = System.Convert.ToString(Outputs["Tel"]);
            }
            catch { }

            try
            {
                Mobile = System.Convert.ToString(Outputs["Mobile"]);
            }
            catch { }

            try
            {
                QQ = System.Convert.ToString(Outputs["QQ"]);
            }
            catch { }

            try
            {
                Email = System.Convert.ToString(Outputs["Email"]);
            }
            catch { }

            try
            {
                PostCode = System.Convert.ToString(Outputs["PostCode"]);
            }
            catch { }

            try
            {
                CityID = System.Convert.ToInt32(Outputs["CityID"]);
            }
            catch { }

            try
            {
                Province = System.Convert.ToString(Outputs["Province"]);
            }
            catch { }

            try
            {
                City = System.Convert.ToString(Outputs["City"]);
            }
            catch { }

            try
            {
                Address = System.Convert.ToString(Outputs["Address"]);
            }
            catch { }

            try
            {
                Fax = System.Convert.ToString(Outputs["Fax"]);
            }
            catch { }

            try
            {
                Other = System.Convert.ToString(Outputs["Other"]);
            }
            catch { }

            try
            {
                BankName = System.Convert.ToString(Outputs["BankName"]);
            }
            catch { }

            try
            {
                BankNameDetail = System.Convert.ToString(Outputs["BankNameDetail"]);
            }
            catch { }

            try
            {
                BankCardNo = System.Convert.ToString(Outputs["BankCardNo"]);
            }
            catch { }

            try
            {
                BankCustName = System.Convert.ToString(Outputs["BankCustName"]);
            }
            catch { }

            try
            {
                RegisterOperID = System.Convert.ToInt64(Outputs["RegisterOperID"]);
            }
            catch { }

            try
            {
                RegisterCustomerNO = System.Convert.ToString(Outputs["RegisterCustomerNO"]);
            }
            catch { }

            try
            {
                RegisterCustomerName = System.Convert.ToString(Outputs["RegisterCustomerName"]);
            }
            catch { }

            try
            {
                RegisterDate = System.Convert.ToDateTime(Outputs["RegisterDate"]);
            }
            catch { }

            try
            {
                VerfyDate = System.Convert.ToDateTime(Outputs["VerfyDate"]);
            }
            catch { }

            try
            {
                VerfyOperatorID = System.Convert.ToInt64(Outputs["VerfyOperatorID"]);
            }
            catch { }

            try
            {
                VerfyCustomerNo = System.Convert.ToString(Outputs["VerfyCustomerNo"]);
            }
            catch { }

            try
            {
                VerfyCustomerName = System.Convert.ToString(Outputs["VerfyCustomerName"]);
            }
            catch { }

            try
            {
                Status = System.Convert.ToInt16(Outputs["Status"]);
            }
            catch { }

            try
            {
                State = System.Convert.ToString(Outputs["State"]);
            }
            catch { }

            try
            {
                Remark = System.Convert.ToString(Outputs["Remark"]);
            }
            catch { }

            try
            {
                SiteTitle = System.Convert.ToString(Outputs["SiteTitle"]);
            }
            catch { }

            try
            {
                SiteURL = System.Convert.ToString(Outputs["SiteURL"]);
            }
            catch { }

            try
            {
                SiteStatus = System.Convert.ToInt16(Outputs["SiteStatus"]);
            }
            catch { }

            try
            {
                SiteQQ = System.Convert.ToString(Outputs["SiteQQ"]);
            }
            catch { }

            try
            {
                SiteTelephone = System.Convert.ToString(Outputs["SiteTelephone"]);
            }
            catch { }

            try
            {
                CopyRightInfo = System.Convert.ToString(Outputs["CopyRightInfo"]);
            }
            catch { }

            try
            {
                ICPCert = System.Convert.ToString(Outputs["ICPCert"]);
            }
            catch { }

            try
            {
                EnterpriseWebSite = System.Convert.ToString(Outputs["EnterpriseWebSite"]);
            }
            catch { }

            try
            {
                EnterpriseWebStatus = System.Convert.ToInt16(Outputs["EnterpriseWebStatus"]);
            }
            catch { }

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                BV = System.Convert.ToDouble(Outputs["BV"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetAccountBaseInfo(ref long RegTotal, ref long DayRegCount, ref double TotalGathering, ref double PayTota, ref double DayBuy, ref double HistoryBuy, ref double CurPlayRatio, ref long TotalNumberOfCopies, ref long DayTotalNumberOfCopies)
        {
            DataSet ds = null;

            return P_GetAccountBaseInfo(ref ds, ref RegTotal, ref DayRegCount, ref TotalGathering, ref PayTota, ref DayBuy, ref HistoryBuy, ref CurPlayRatio, ref TotalNumberOfCopies, ref DayTotalNumberOfCopies);
        }

        public static int P_GetAccountBaseInfo(ref DataSet ds, ref long RegTotal, ref long DayRegCount, ref double TotalGathering, ref double PayTota, ref double DayBuy, ref double HistoryBuy, ref double CurPlayRatio, ref long TotalNumberOfCopies, ref long DayTotalNumberOfCopies)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetAccountBaseInfo", ref ds, ref Outputs,
                new MSSQL.Parameter("RegTotal", SqlDbType.BigInt, 8, ParameterDirection.Output, RegTotal),
                new MSSQL.Parameter("DayRegCount", SqlDbType.BigInt, 8, ParameterDirection.Output, DayRegCount),
                new MSSQL.Parameter("TotalGathering", SqlDbType.Money, 8, ParameterDirection.Output, TotalGathering),
                new MSSQL.Parameter("PayTota", SqlDbType.Money, 8, ParameterDirection.Output, PayTota),
                new MSSQL.Parameter("DayBuy", SqlDbType.Money, 8, ParameterDirection.Output, DayBuy),
                new MSSQL.Parameter("HistoryBuy", SqlDbType.Money, 8, ParameterDirection.Output, HistoryBuy),
                new MSSQL.Parameter("CurPlayRatio", SqlDbType.Float, 8, ParameterDirection.Output, CurPlayRatio),
                new MSSQL.Parameter("TotalNumberOfCopies", SqlDbType.BigInt, 8, ParameterDirection.Output, TotalNumberOfCopies),
                new MSSQL.Parameter("DayTotalNumberOfCopies", SqlDbType.BigInt, 8, ParameterDirection.Output, DayTotalNumberOfCopies)
                );

            try
            {
                RegTotal = System.Convert.ToInt64(Outputs["RegTotal"]);
            }
            catch { }

            try
            {
                DayRegCount = System.Convert.ToInt64(Outputs["DayRegCount"]);
            }
            catch { }

            try
            {
                TotalGathering = System.Convert.ToDouble(Outputs["TotalGathering"]);
            }
            catch { }

            try
            {
                PayTota = System.Convert.ToDouble(Outputs["PayTota"]);
            }
            catch { }

            try
            {
                DayBuy = System.Convert.ToDouble(Outputs["DayBuy"]);
            }
            catch { }

            try
            {
                HistoryBuy = System.Convert.ToDouble(Outputs["HistoryBuy"]);
            }
            catch { }

            try
            {
                CurPlayRatio = System.Convert.ToDouble(Outputs["CurPlayRatio"]);
            }
            catch { }

            try
            {
                TotalNumberOfCopies = System.Convert.ToInt64(Outputs["TotalNumberOfCopies"]);
            }
            catch { }

            try
            {
                DayTotalNumberOfCopies = System.Convert.ToInt64(Outputs["DayTotalNumberOfCopies"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_SetCustomerCompetences(long CustomerID, string CompetencesList, string GroupsList, long ShopID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_SetCustomerCompetences(ref ds, CustomerID, CompetencesList, GroupsList, ShopID, ref ReturnDescription);
        }

        public static int P_SetCustomerCompetences(ref DataSet ds, long CustomerID, string CompetencesList, string GroupsList, long ShopID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_SetCustomerCompetences", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("CompetencesList", SqlDbType.VarChar, 0, ParameterDirection.Input, CompetencesList),
                new MSSQL.Parameter("GroupsList", SqlDbType.VarChar, 0, ParameterDirection.Input, GroupsList),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetManagerLoginInfo(long CustomerID, ref long ManagerCount, ref string AferUser, ref string AfterIp, ref DateTime LoginAfterTime, ref string UserIp, ref DateTime UserLoginTime)
        {
            DataSet ds = null;

            return P_GetManagerLoginInfo(ref ds, CustomerID, ref ManagerCount, ref AferUser, ref AfterIp, ref LoginAfterTime, ref UserIp, ref UserLoginTime);
        }

        public static int P_GetManagerLoginInfo(ref DataSet ds, long CustomerID, ref long ManagerCount, ref string AferUser, ref string AfterIp, ref DateTime LoginAfterTime, ref string UserIp, ref DateTime UserLoginTime)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetManagerLoginInfo", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("ManagerCount", SqlDbType.BigInt, 8, ParameterDirection.Output, ManagerCount),
                new MSSQL.Parameter("AferUser", SqlDbType.VarChar, 50, ParameterDirection.Output, AferUser),
                new MSSQL.Parameter("AfterIp", SqlDbType.VarChar, 50, ParameterDirection.Output, AfterIp),
                new MSSQL.Parameter("LoginAfterTime", SqlDbType.DateTime, 8, ParameterDirection.Output, LoginAfterTime),
                new MSSQL.Parameter("UserIp", SqlDbType.VarChar, 50, ParameterDirection.Output, UserIp),
                new MSSQL.Parameter("UserLoginTime", SqlDbType.DateTime, 8, ParameterDirection.Output, UserLoginTime)
                );

            try
            {
                ManagerCount = System.Convert.ToInt64(Outputs["ManagerCount"]);
            }
            catch { }

            try
            {
                AferUser = System.Convert.ToString(Outputs["AferUser"]);
            }
            catch { }

            try
            {
                AfterIp = System.Convert.ToString(Outputs["AfterIp"]);
            }
            catch { }

            try
            {
                LoginAfterTime = System.Convert.ToDateTime(Outputs["LoginAfterTime"]);
            }
            catch { }

            try
            {
                UserIp = System.Convert.ToString(Outputs["UserIp"]);
            }
            catch { }

            try
            {
                UserLoginTime = System.Convert.ToDateTime(Outputs["UserLoginTime"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetCustomerCompetences(long CustomerID)
        {
            DataSet ds = null;

            return P_GetCustomerCompetences(ref ds, CustomerID);
        }

        public static int P_GetCustomerCompetences(ref DataSet ds, long CustomerID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerCompetences", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID)
                );

            return CallResult;
        }

        public static int P_InComingOrOutComing(DateTime StartDateTime, DateTime EndDateTime, int Type, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_InComingOrOutComing(ref ds, StartDateTime, EndDateTime, Type, ref ReturnDescription);
        }

        public static int P_InComingOrOutComing(ref DataSet ds, DateTime StartDateTime, DateTime EndDateTime, int Type, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_InComingOrOutComing", ref ds, ref Outputs,
                new MSSQL.Parameter("StartDateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, StartDateTime),
                new MSSQL.Parameter("EndDateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, EndDateTime),
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetCustomerBonus(long CustomerID, int Year)
        {
            DataSet ds = null;

            return P_GetCustomerBonus(ref ds, CustomerID, Year);
        }

        public static int P_GetCustomerBonus(ref DataSet ds, long CustomerID, int Year)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerBonus", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Year", SqlDbType.Int, 0, ParameterDirection.Input, Year)
                );

            return CallResult;
        }

        public static int P_CustomerDistill(long ShopID, long CustomerID, double Money, string BankName, string BankCardNumber, string Memo, double DistillFormalitiesFeesScale, long OperatorID, int PaymentType, long PaymentFilesID, int Type, ref int ResultValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerDistill(ref ds, ShopID, CustomerID, Money, BankName, BankCardNumber, Memo, DistillFormalitiesFeesScale, OperatorID, PaymentType, PaymentFilesID, Type, ref ResultValue, ref ReturnDescription);
        }

        public static int P_CustomerDistill(ref DataSet ds, long ShopID, long CustomerID, double Money, string BankName, string BankCardNumber, string Memo, double DistillFormalitiesFeesScale, long OperatorID, int PaymentType, long PaymentFilesID, int Type, ref int ResultValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerDistill", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("BankName", SqlDbType.VarChar, 0, ParameterDirection.Input, BankName),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNumber),
                new MSSQL.Parameter("Memo", SqlDbType.VarChar, 0, ParameterDirection.Input, Memo),
                new MSSQL.Parameter("DistillFormalitiesFeesScale", SqlDbType.Money, 0, ParameterDirection.Input, DistillFormalitiesFeesScale),
                new MSSQL.Parameter("OperatorID", SqlDbType.BigInt, 0, ParameterDirection.Input, OperatorID),
                new MSSQL.Parameter("PaymentType", SqlDbType.Int, 0, ParameterDirection.Input, PaymentType),
                new MSSQL.Parameter("PaymentFilesID", SqlDbType.BigInt, 0, ParameterDirection.Input, PaymentFilesID),
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("ResultValue", SqlDbType.Int, 4, ParameterDirection.Output, ResultValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ResultValue = System.Convert.ToInt32(Outputs["ResultValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_CustomerDistillAll(long OperatorID, int PaymentType, long PaymentFilesID, int Type, ref int ResultValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerDistillAll(ref ds, OperatorID, PaymentType, PaymentFilesID, Type, ref ResultValue, ref ReturnDescription);
        }

        public static int P_CustomerDistillAll(ref DataSet ds, long OperatorID, int PaymentType, long PaymentFilesID, int Type, ref int ResultValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerDistillAll", ref ds, ref Outputs,
                new MSSQL.Parameter("OperatorID", SqlDbType.BigInt, 0, ParameterDirection.Input, OperatorID),
                new MSSQL.Parameter("PaymentType", SqlDbType.Int, 0, ParameterDirection.Input, PaymentType),
                new MSSQL.Parameter("PaymentFilesID", SqlDbType.BigInt, 0, ParameterDirection.Input, PaymentFilesID),
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("ResultValue", SqlDbType.Int, 4, ParameterDirection.Output, ResultValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ResultValue = System.Convert.ToInt32(Outputs["ResultValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_CustomerDistillUpdate(long ID, long CustomerID, double Money, long OperatorID, ref int Result, ref string Return)
        {
            DataSet ds = null;

            return P_CustomerDistillUpdate(ref ds, ID, CustomerID, Money, OperatorID, ref Result, ref Return);
        }

        public static int P_CustomerDistillUpdate(ref DataSet ds, long ID, long CustomerID, double Money, long OperatorID, ref int Result, ref string Return)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerDistillUpdate", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Money", SqlDbType.Money, 0, ParameterDirection.Input, Money),
                new MSSQL.Parameter("OperatorID", SqlDbType.BigInt, 0, ParameterDirection.Input, OperatorID),
                new MSSQL.Parameter("Result", SqlDbType.Int, 4, ParameterDirection.Output, Result),
                new MSSQL.Parameter("Return", SqlDbType.VarChar, 100, ParameterDirection.Output, Return)
                );

            try
            {
                Result = System.Convert.ToInt32(Outputs["Result"]);
            }
            catch { }

            try
            {
                Return = System.Convert.ToString(Outputs["Return"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_CustomerDistillsUpdate(string FileName, string IDs, int PaymentType, int OperatorType)
        {
            DataSet ds = null;

            return P_CustomerDistillsUpdate(ref ds, FileName, IDs, PaymentType, OperatorType);
        }

        public static int P_CustomerDistillsUpdate(ref DataSet ds, string FileName, string IDs, int PaymentType, int OperatorType)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerDistillsUpdate", ref ds, ref Outputs,
                new MSSQL.Parameter("FileName", SqlDbType.VarChar, 0, ParameterDirection.Input, FileName),
                new MSSQL.Parameter("IDs", SqlDbType.VarChar, 0, ParameterDirection.Input, IDs),
                new MSSQL.Parameter("PaymentType", SqlDbType.Int, 0, ParameterDirection.Input, PaymentType),
                new MSSQL.Parameter("OperatorType", SqlDbType.Int, 0, ParameterDirection.Input, OperatorType)
                );

            return CallResult;
        }

        public static int P_PageChange(int Type, string Field1, string Field2, string like1, string like2, string TableName, int PageIndex, int PageSize, string Condition)
        {
            DataSet ds = null;

            return P_PageChange(ref ds, Type, Field1, Field2, like1, like2, TableName, PageIndex, PageSize, Condition);
        }

        public static int P_PageChange(ref DataSet ds, int Type, string Field1, string Field2, string like1, string like2, string TableName, int PageIndex, int PageSize, string Condition)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_PageChange", ref ds, ref Outputs,
                new MSSQL.Parameter("Type", SqlDbType.Int, 0, ParameterDirection.Input, Type),
                new MSSQL.Parameter("Field1", SqlDbType.VarChar, 0, ParameterDirection.Input, Field1),
                new MSSQL.Parameter("Field2", SqlDbType.VarChar, 0, ParameterDirection.Input, Field2),
                new MSSQL.Parameter("like1", SqlDbType.VarChar, 0, ParameterDirection.Input, like1),
                new MSSQL.Parameter("like2", SqlDbType.VarChar, 0, ParameterDirection.Input, like2),
                new MSSQL.Parameter("TableName", SqlDbType.VarChar, 0, ParameterDirection.Input, TableName),
                new MSSQL.Parameter("PageIndex", SqlDbType.Int, 0, ParameterDirection.Input, PageIndex),
                new MSSQL.Parameter("PageSize", SqlDbType.Int, 0, ParameterDirection.Input, PageSize),
                new MSSQL.Parameter("Condition", SqlDbType.VarChar, 0, ParameterDirection.Input, Condition)
                );

            return CallResult;
        }

        public static int P_Shop_DelProcurement_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelProcurement_Master(ref ds, ID);
        }

        public static int P_Shop_DelProcurement_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelProcurement_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_CheckProcurement(long InID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckProcurement(ref ds, InID, VerfyOperID);
        }

        public static int P_Shop_CheckProcurement(ref DataSet ds, long InID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckProcurement", ref ds, ref Outputs,
                new MSSQL.Parameter("InID", SqlDbType.BigInt, 0, ParameterDirection.Input, InID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_GetNet(long CustomerID)
        {
            DataSet ds = null;

            return P_GetNet(ref ds, CustomerID);
        }

        public static int P_GetNet(ref DataSet ds, long CustomerID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetNet", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID)
                );

            return CallResult;
        }

        public static int P_Shop_DelRequestGood_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelRequestGood_Master(ref ds, ID);
        }

        public static int P_Shop_DelRequestGood_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelRequestGood_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_CheckRequestGood(long ID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckRequestGood(ref ds, ID, VerfyOperID);
        }

        public static int P_Shop_CheckRequestGood(ref DataSet ds, long ID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckRequestGood", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_Shop_EditDepotOutDetail(long ID, long OutID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditDepotOutDetail(ref ds, ID, OutID, GoodID, Amount);
        }

        public static int P_Shop_EditDepotOutDetail(ref DataSet ds, long ID, long OutID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditDepotOutDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("OutID", SqlDbType.BigInt, 0, ParameterDirection.Input, OutID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_Shop_DelShipmentMaster(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelShipmentMaster(ref ds, ID);
        }

        public static int P_Shop_DelShipmentMaster(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelShipmentMaster", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_DelDepotIN_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelDepotIN_Master(ref ds, ID);
        }

        public static int P_Shop_DelDepotIN_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelDepotIN_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_DelDepotOutMaster(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelDepotOutMaster(ref ds, ID);
        }

        public static int P_Shop_DelDepotOutMaster(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelDepotOutMaster", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_DelDepotINMaster(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelDepotINMaster(ref ds, ID);
        }

        public static int P_Shop_DelDepotINMaster(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelDepotINMaster", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_CheckDepotIN(long InID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckDepotIN(ref ds, InID, VerfyOperID);
        }

        public static int P_Shop_CheckDepotIN(ref DataSet ds, long InID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckDepotIN", ref ds, ref Outputs,
                new MSSQL.Parameter("InID", SqlDbType.BigInt, 0, ParameterDirection.Input, InID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_CustomerEditByNo(string CustomerNO, string CustomerName, short CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNumber, string BankCustName, string AlipayNo, int DeptID, long RegisterOperID, DateTime RegisterDate, long VerfyOperID, DateTime VerfyDate, short Status, string Remark, long ShopID, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, short LR, bool isLock, bool isActivation, bool IsSurrogate, double Balance, double Freeze, double Earning, double EarningBalance, double EarningBalance2, double Earning2, double Earning3, double EarningBalance3, double PV, double BV, DateTime UpVipDate, DateTime LastLoginTime, string LastLoginIP, int LoginNum, ref int ReturnValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerEditByNo(ref ds, CustomerNO, CustomerName, CustomerTypeID, Password1, Password2, Tel, Mobile, QQ, Email, PostCode, CityID, Address, Fax, Other, Sex, Birthday, CertTypeID, CertNo, BankTypeID, BankNameDetail, BankCardNumber, BankCustName, AlipayNo, DeptID, RegisterOperID, RegisterDate, VerfyOperID, VerfyDate, Status, Remark, ShopID, RegisterShopID, SurrogateID, CommendID, ParentID, LR, isLock, isActivation, IsSurrogate, Balance, Freeze, Earning, EarningBalance, EarningBalance2, Earning2, Earning3, EarningBalance3, PV, BV, UpVipDate, LastLoginTime, LastLoginIP, LoginNum, ref ReturnValue, ref ReturnDescription);
        }

        public static int P_CustomerEditByNo(ref DataSet ds, string CustomerNO, string CustomerName, short CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNumber, string BankCustName, string AlipayNo, int DeptID, long RegisterOperID, DateTime RegisterDate, long VerfyOperID, DateTime VerfyDate, short Status, string Remark, long ShopID, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, short LR, bool isLock, bool isActivation, bool IsSurrogate, double Balance, double Freeze, double Earning, double EarningBalance, double EarningBalance2, double Earning2, double Earning3, double EarningBalance3, double PV, double BV, DateTime UpVipDate, DateTime LastLoginTime, string LastLoginIP, int LoginNum, ref int ReturnValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerEditByNo", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerNO", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerNO),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CustomerTypeID),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 0, ParameterDirection.Input, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 0, ParameterDirection.Input, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 0, ParameterDirection.Input, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 0, ParameterDirection.Input, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 0, ParameterDirection.Input, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 0, ParameterDirection.Input, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 0, ParameterDirection.Input, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 0, ParameterDirection.Input, CityID),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 0, ParameterDirection.Input, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 0, ParameterDirection.Input, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 0, ParameterDirection.Input, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 0, ParameterDirection.Input, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 0, ParameterDirection.Input, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CertTypeID),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 0, ParameterDirection.Input, BankTypeID),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 0, ParameterDirection.Input, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCustName),
                new MSSQL.Parameter("AlipayNo", SqlDbType.VarChar, 0, ParameterDirection.Input, AlipayNo),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 0, ParameterDirection.Input, DeptID),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterOperID),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 0, ParameterDirection.Input, RegisterDate),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 0, ParameterDirection.Input, VerfyDate),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 0, ParameterDirection.Input, Status),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterShopID),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 0, ParameterDirection.Input, CommendID),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 0, ParameterDirection.Input, ParentID),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 0, ParameterDirection.Input, LR),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 0, ParameterDirection.Input, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 0, ParameterDirection.Input, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 0, ParameterDirection.Input, IsSurrogate),
                new MSSQL.Parameter("Balance", SqlDbType.Money, 0, ParameterDirection.Input, Balance),
                new MSSQL.Parameter("Freeze", SqlDbType.Money, 0, ParameterDirection.Input, Freeze),
                new MSSQL.Parameter("Earning", SqlDbType.Money, 0, ParameterDirection.Input, Earning),
                new MSSQL.Parameter("EarningBalance", SqlDbType.Money, 0, ParameterDirection.Input, EarningBalance),
                new MSSQL.Parameter("EarningBalance2", SqlDbType.Money, 0, ParameterDirection.Input, EarningBalance2),
                new MSSQL.Parameter("Earning2", SqlDbType.Money, 0, ParameterDirection.Input, Earning2),
                new MSSQL.Parameter("Earning3", SqlDbType.Money, 0, ParameterDirection.Input, Earning3),
                new MSSQL.Parameter("EarningBalance3", SqlDbType.Money, 0, ParameterDirection.Input, EarningBalance3),
                new MSSQL.Parameter("PV", SqlDbType.Money, 0, ParameterDirection.Input, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 0, ParameterDirection.Input, BV),
                new MSSQL.Parameter("UpVipDate", SqlDbType.DateTime, 0, ParameterDirection.Input, UpVipDate),
                new MSSQL.Parameter("LastLoginTime", SqlDbType.DateTime, 0, ParameterDirection.Input, LastLoginTime),
                new MSSQL.Parameter("LastLoginIP", SqlDbType.VarChar, 0, ParameterDirection.Input, LastLoginIP),
                new MSSQL.Parameter("LoginNum", SqlDbType.Int, 0, ParameterDirection.Input, LoginNum),
                new MSSQL.Parameter("ReturnValue", SqlDbType.Int, 4, ParameterDirection.Output, ReturnValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnValue = System.Convert.ToInt32(Outputs["ReturnValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Earning7(DateTime DateTime)
        {
            DataSet ds = null;

            return P_Earning7(ref ds, DateTime);
        }

        public static int P_Earning7(ref DataSet ds, DateTime DateTime)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Earning7", ref ds, ref Outputs,
                new MSSQL.Parameter("DateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, DateTime)
                );

            return CallResult;
        }

        public static int P_CustomerEditByID(long ID, string CustomerNO, string CustomerName, short CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNumber, string BankCustName, string AlipayNo, int DeptID, long RegisterOperID, DateTime RegisterDate, long VerfyOperID, DateTime VerfyDate, short Status, string Remark, long ShopID, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, short LR, bool isLock, bool isActivation, bool IsSurrogate, double Balance, double Freeze, double Earning, double EarningBalance, double EarningBalance2, double Earning2, double Earning3, double EarningBalance3, double PV, double BV, DateTime UpVipDate, DateTime LastLoginTime, string LastLoginIP, int LoginNum, ref int ReturnValue, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_CustomerEditByID(ref ds, ID, CustomerNO, CustomerName, CustomerTypeID, Password1, Password2, Tel, Mobile, QQ, Email, PostCode, CityID, Address, Fax, Other, Sex, Birthday, CertTypeID, CertNo, BankTypeID, BankNameDetail, BankCardNumber, BankCustName, AlipayNo, DeptID, RegisterOperID, RegisterDate, VerfyOperID, VerfyDate, Status, Remark, ShopID, RegisterShopID, SurrogateID, CommendID, ParentID, LR, isLock, isActivation, IsSurrogate, Balance, Freeze, Earning, EarningBalance, EarningBalance2, Earning2, Earning3, EarningBalance3, PV, BV, UpVipDate, LastLoginTime, LastLoginIP, LoginNum, ref ReturnValue, ref ReturnDescription);
        }

        public static int P_CustomerEditByID(ref DataSet ds, long ID, string CustomerNO, string CustomerName, short CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNumber, string BankCustName, string AlipayNo, int DeptID, long RegisterOperID, DateTime RegisterDate, long VerfyOperID, DateTime VerfyDate, short Status, string Remark, long ShopID, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, short LR, bool isLock, bool isActivation, bool IsSurrogate, double Balance, double Freeze, double Earning, double EarningBalance, double EarningBalance2, double Earning2, double Earning3, double EarningBalance3, double PV, double BV, DateTime UpVipDate, DateTime LastLoginTime, string LastLoginIP, int LoginNum, ref int ReturnValue, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_CustomerEditByID", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("CustomerNO", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerNO),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CustomerTypeID),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 0, ParameterDirection.Input, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 0, ParameterDirection.Input, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 0, ParameterDirection.Input, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 0, ParameterDirection.Input, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 0, ParameterDirection.Input, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 0, ParameterDirection.Input, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 0, ParameterDirection.Input, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 0, ParameterDirection.Input, CityID),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 0, ParameterDirection.Input, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 0, ParameterDirection.Input, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 0, ParameterDirection.Input, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 0, ParameterDirection.Input, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 0, ParameterDirection.Input, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CertTypeID),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 0, ParameterDirection.Input, BankTypeID),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 0, ParameterDirection.Input, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCustName),
                new MSSQL.Parameter("AlipayNo", SqlDbType.VarChar, 0, ParameterDirection.Input, AlipayNo),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 0, ParameterDirection.Input, DeptID),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterOperID),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 0, ParameterDirection.Input, RegisterDate),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 0, ParameterDirection.Input, VerfyDate),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 0, ParameterDirection.Input, Status),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopID),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterShopID),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 0, ParameterDirection.Input, CommendID),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 0, ParameterDirection.Input, ParentID),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 0, ParameterDirection.Input, LR),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 0, ParameterDirection.Input, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 0, ParameterDirection.Input, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 0, ParameterDirection.Input, IsSurrogate),
                new MSSQL.Parameter("Balance", SqlDbType.Money, 0, ParameterDirection.Input, Balance),
                new MSSQL.Parameter("Freeze", SqlDbType.Money, 0, ParameterDirection.Input, Freeze),
                new MSSQL.Parameter("Earning", SqlDbType.Money, 0, ParameterDirection.Input, Earning),
                new MSSQL.Parameter("EarningBalance", SqlDbType.Money, 0, ParameterDirection.Input, EarningBalance),
                new MSSQL.Parameter("EarningBalance2", SqlDbType.Money, 0, ParameterDirection.Input, EarningBalance2),
                new MSSQL.Parameter("Earning2", SqlDbType.Money, 0, ParameterDirection.Input, Earning2),
                new MSSQL.Parameter("Earning3", SqlDbType.Money, 0, ParameterDirection.Input, Earning3),
                new MSSQL.Parameter("EarningBalance3", SqlDbType.Money, 0, ParameterDirection.Input, EarningBalance3),
                new MSSQL.Parameter("PV", SqlDbType.Money, 0, ParameterDirection.Input, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 0, ParameterDirection.Input, BV),
                new MSSQL.Parameter("UpVipDate", SqlDbType.DateTime, 0, ParameterDirection.Input, UpVipDate),
                new MSSQL.Parameter("LastLoginTime", SqlDbType.DateTime, 0, ParameterDirection.Input, LastLoginTime),
                new MSSQL.Parameter("LastLoginIP", SqlDbType.VarChar, 0, ParameterDirection.Input, LastLoginIP),
                new MSSQL.Parameter("LoginNum", SqlDbType.Int, 0, ParameterDirection.Input, LoginNum),
                new MSSQL.Parameter("ReturnValue", SqlDbType.Int, 4, ParameterDirection.Output, ReturnValue),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnValue = System.Convert.ToInt32(Outputs["ReturnValue"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_DelDepotOut_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelDepotOut_Master(ref ds, ID);
        }

        public static int P_Shop_DelDepotOut_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelDepotOut_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_GetCustomerInformationByNo(string CustomerNO, long ShopSiteID, ref long CustomerID, ref string CustomerName, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int ProvinceID, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double FundManage, ref double Tax, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_GetCustomerInformationByNo(ref ds, CustomerNO, ShopSiteID, ref CustomerID, ref CustomerName, ref CustomerTypeID, ref CustomerTypeName, ref IsAward, ref Password1, ref Password2, ref Tel, ref Mobile, ref QQ, ref Email, ref PostCode, ref ProvinceID, ref CityID, ref Province, ref City, ref Address, ref Fax, ref Other, ref Sex, ref Birthday, ref CertTypeID, ref CertTypeName, ref CertNo, ref BankTypeID, ref BankTypeName, ref BankNameDetail, ref BankCardNumber, ref BankCustName, ref AlipayNo, ref DeptID, ref DeparmenttName, ref RegisterOperID, ref RegisterCustomerNO, ref RegisterCustomerName, ref RegisterDate, ref VerfyOperID, ref VerfyCustomerNO, ref VerfyCustomerName, ref VerfyDate, ref Status, ref State, ref Remark, ref ShopNo, ref ShopName, ref ShopID, ref RegisterShopID, ref RegisterShopNO, ref RegisterShopName, ref SurrogateID, ref SurrogateNO, ref SurrogateName, ref CommendID, ref CommendCustomerNO, ref CommendCustomerName, ref ParentID, ref ParentCustomerNO, ref ParentCustomerName, ref LR, ref isLock, ref isActivation, ref IsSurrogate, ref Balance, ref Freeze, ref Earning, ref EarningBalance, ref EarningBalance2, ref Earning2, ref Earning3, ref EarningBalance3, ref FundManage, ref Tax, ref PV, ref BV, ref UpVipDate, ref LastLoginTime, ref LastLoginIP, ref LoginNum, ref OwnerCustomerID, ref isOwnerCustomer, ref isShopAgent, ref ReturnDescription);
        }

        public static int P_GetCustomerInformationByNo(ref DataSet ds, string CustomerNO, long ShopSiteID, ref long CustomerID, ref string CustomerName, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int ProvinceID, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double FundManage, ref double Tax, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerInformationByNo", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerNO", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerNO),
                new MSSQL.Parameter("ShopSiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopSiteID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CustomerTypeID),
                new MSSQL.Parameter("CustomerTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerTypeName),
                new MSSQL.Parameter("IsAward", SqlDbType.Bit, 1, ParameterDirection.Output, IsAward),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 50, ParameterDirection.Output, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 50, ParameterDirection.Output, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 50, ParameterDirection.Output, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 50, ParameterDirection.Output, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 50, ParameterDirection.Output, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 50, ParameterDirection.Output, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 50, ParameterDirection.Output, PostCode),
                new MSSQL.Parameter("ProvinceID", SqlDbType.Int, 4, ParameterDirection.Output, ProvinceID),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 4, ParameterDirection.Output, CityID),
                new MSSQL.Parameter("Province", SqlDbType.VarChar, 50, ParameterDirection.Output, Province),
                new MSSQL.Parameter("City", SqlDbType.VarChar, 50, ParameterDirection.Output, City),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 50, ParameterDirection.Output, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 50, ParameterDirection.Output, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 50, ParameterDirection.Output, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 50, ParameterDirection.Output, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 8, ParameterDirection.Output, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CertTypeID),
                new MSSQL.Parameter("CertTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CertTypeName),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 4, ParameterDirection.Output, BankTypeID),
                new MSSQL.Parameter("BankTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankTypeName),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 50, ParameterDirection.Output, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCustName),
                new MSSQL.Parameter("AlipayNo", SqlDbType.VarChar, 50, ParameterDirection.Output, AlipayNo),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 4, ParameterDirection.Output, DeptID),
                new MSSQL.Parameter("DeparmenttName", SqlDbType.VarChar, 50, ParameterDirection.Output, DeparmenttName),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterOperID),
                new MSSQL.Parameter("RegisterCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerNO),
                new MSSQL.Parameter("RegisterCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerName),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 8, ParameterDirection.Output, RegisterDate),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, VerfyOperID),
                new MSSQL.Parameter("VerfyCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerNO),
                new MSSQL.Parameter("VerfyCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerName),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 8, ParameterDirection.Output, VerfyDate),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 1, ParameterDirection.Output, Status),
                new MSSQL.Parameter("State", SqlDbType.VarChar, 50, ParameterDirection.Output, State),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 255, ParameterDirection.Output, Remark),
                new MSSQL.Parameter("ShopNo", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopNo),
                new MSSQL.Parameter("ShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopName),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterShopID),
                new MSSQL.Parameter("RegisterShopNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopNO),
                new MSSQL.Parameter("RegisterShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopName),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 8, ParameterDirection.Output, SurrogateID),
                new MSSQL.Parameter("SurrogateNO", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateNO),
                new MSSQL.Parameter("SurrogateName", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateName),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 8, ParameterDirection.Output, CommendID),
                new MSSQL.Parameter("CommendCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerNO),
                new MSSQL.Parameter("CommendCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerName),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 8, ParameterDirection.Output, ParentID),
                new MSSQL.Parameter("ParentCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerNO),
                new MSSQL.Parameter("ParentCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerName),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 1, ParameterDirection.Output, LR),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 1, ParameterDirection.Output, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 1, ParameterDirection.Output, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 1, ParameterDirection.Output, IsSurrogate),
                new MSSQL.Parameter("Balance", SqlDbType.Money, 8, ParameterDirection.Output, Balance),
                new MSSQL.Parameter("Freeze", SqlDbType.Money, 8, ParameterDirection.Output, Freeze),
                new MSSQL.Parameter("Earning", SqlDbType.Money, 8, ParameterDirection.Output, Earning),
                new MSSQL.Parameter("EarningBalance", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance),
                new MSSQL.Parameter("EarningBalance2", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance2),
                new MSSQL.Parameter("Earning2", SqlDbType.Money, 8, ParameterDirection.Output, Earning2),
                new MSSQL.Parameter("Earning3", SqlDbType.Money, 8, ParameterDirection.Output, Earning3),
                new MSSQL.Parameter("EarningBalance3", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance3),
                new MSSQL.Parameter("FundManage", SqlDbType.Money, 8, ParameterDirection.Output, FundManage),
                new MSSQL.Parameter("Tax", SqlDbType.Money, 8, ParameterDirection.Output, Tax),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 8, ParameterDirection.Output, BV),
                new MSSQL.Parameter("UpVipDate", SqlDbType.DateTime, 8, ParameterDirection.Output, UpVipDate),
                new MSSQL.Parameter("LastLoginTime", SqlDbType.DateTime, 8, ParameterDirection.Output, LastLoginTime),
                new MSSQL.Parameter("LastLoginIP", SqlDbType.VarChar, 50, ParameterDirection.Output, LastLoginIP),
                new MSSQL.Parameter("LoginNum", SqlDbType.Int, 4, ParameterDirection.Output, LoginNum),
                new MSSQL.Parameter("OwnerCustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, OwnerCustomerID),
                new MSSQL.Parameter("isOwnerCustomer", SqlDbType.Bit, 1, ParameterDirection.Output, isOwnerCustomer),
                new MSSQL.Parameter("isShopAgent", SqlDbType.Bit, 1, ParameterDirection.Output, isShopAgent),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                CustomerName = System.Convert.ToString(Outputs["CustomerName"]);
            }
            catch { }

            try
            {
                CustomerTypeID = System.Convert.ToInt16(Outputs["CustomerTypeID"]);
            }
            catch { }

            try
            {
                CustomerTypeName = System.Convert.ToString(Outputs["CustomerTypeName"]);
            }
            catch { }

            try
            {
                IsAward = System.Convert.ToBoolean(Outputs["IsAward"]);
            }
            catch { }

            try
            {
                Password1 = System.Convert.ToString(Outputs["Password1"]);
            }
            catch { }

            try
            {
                Password2 = System.Convert.ToString(Outputs["Password2"]);
            }
            catch { }

            try
            {
                Tel = System.Convert.ToString(Outputs["Tel"]);
            }
            catch { }

            try
            {
                Mobile = System.Convert.ToString(Outputs["Mobile"]);
            }
            catch { }

            try
            {
                QQ = System.Convert.ToString(Outputs["QQ"]);
            }
            catch { }

            try
            {
                Email = System.Convert.ToString(Outputs["Email"]);
            }
            catch { }

            try
            {
                PostCode = System.Convert.ToString(Outputs["PostCode"]);
            }
            catch { }

            try
            {
                ProvinceID = System.Convert.ToInt32(Outputs["ProvinceID"]);
            }
            catch { }

            try
            {
                CityID = System.Convert.ToInt32(Outputs["CityID"]);
            }
            catch { }

            try
            {
                Province = System.Convert.ToString(Outputs["Province"]);
            }
            catch { }

            try
            {
                City = System.Convert.ToString(Outputs["City"]);
            }
            catch { }

            try
            {
                Address = System.Convert.ToString(Outputs["Address"]);
            }
            catch { }

            try
            {
                Fax = System.Convert.ToString(Outputs["Fax"]);
            }
            catch { }

            try
            {
                Other = System.Convert.ToString(Outputs["Other"]);
            }
            catch { }

            try
            {
                Sex = System.Convert.ToString(Outputs["Sex"]);
            }
            catch { }

            try
            {
                Birthday = System.Convert.ToDateTime(Outputs["Birthday"]);
            }
            catch { }

            try
            {
                CertTypeID = System.Convert.ToInt16(Outputs["CertTypeID"]);
            }
            catch { }

            try
            {
                CertTypeName = System.Convert.ToString(Outputs["CertTypeName"]);
            }
            catch { }

            try
            {
                CertNo = System.Convert.ToString(Outputs["CertNo"]);
            }
            catch { }

            try
            {
                BankTypeID = System.Convert.ToInt32(Outputs["BankTypeID"]);
            }
            catch { }

            try
            {
                BankTypeName = System.Convert.ToString(Outputs["BankTypeName"]);
            }
            catch { }

            try
            {
                BankNameDetail = System.Convert.ToString(Outputs["BankNameDetail"]);
            }
            catch { }

            try
            {
                BankCardNumber = System.Convert.ToString(Outputs["BankCardNumber"]);
            }
            catch { }

            try
            {
                BankCustName = System.Convert.ToString(Outputs["BankCustName"]);
            }
            catch { }

            try
            {
                AlipayNo = System.Convert.ToString(Outputs["AlipayNo"]);
            }
            catch { }

            try
            {
                DeptID = System.Convert.ToInt32(Outputs["DeptID"]);
            }
            catch { }

            try
            {
                DeparmenttName = System.Convert.ToString(Outputs["DeparmenttName"]);
            }
            catch { }

            try
            {
                RegisterOperID = System.Convert.ToInt64(Outputs["RegisterOperID"]);
            }
            catch { }

            try
            {
                RegisterCustomerNO = System.Convert.ToString(Outputs["RegisterCustomerNO"]);
            }
            catch { }

            try
            {
                RegisterCustomerName = System.Convert.ToString(Outputs["RegisterCustomerName"]);
            }
            catch { }

            try
            {
                RegisterDate = System.Convert.ToDateTime(Outputs["RegisterDate"]);
            }
            catch { }

            try
            {
                VerfyOperID = System.Convert.ToInt64(Outputs["VerfyOperID"]);
            }
            catch { }

            try
            {
                VerfyCustomerNO = System.Convert.ToString(Outputs["VerfyCustomerNO"]);
            }
            catch { }

            try
            {
                VerfyCustomerName = System.Convert.ToString(Outputs["VerfyCustomerName"]);
            }
            catch { }

            try
            {
                VerfyDate = System.Convert.ToDateTime(Outputs["VerfyDate"]);
            }
            catch { }

            try
            {
                Status = System.Convert.ToInt16(Outputs["Status"]);
            }
            catch { }

            try
            {
                State = System.Convert.ToString(Outputs["State"]);
            }
            catch { }

            try
            {
                Remark = System.Convert.ToString(Outputs["Remark"]);
            }
            catch { }

            try
            {
                ShopNo = System.Convert.ToString(Outputs["ShopNo"]);
            }
            catch { }

            try
            {
                ShopName = System.Convert.ToString(Outputs["ShopName"]);
            }
            catch { }

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                RegisterShopID = System.Convert.ToInt64(Outputs["RegisterShopID"]);
            }
            catch { }

            try
            {
                RegisterShopNO = System.Convert.ToString(Outputs["RegisterShopNO"]);
            }
            catch { }

            try
            {
                RegisterShopName = System.Convert.ToString(Outputs["RegisterShopName"]);
            }
            catch { }

            try
            {
                SurrogateID = System.Convert.ToInt64(Outputs["SurrogateID"]);
            }
            catch { }

            try
            {
                SurrogateNO = System.Convert.ToString(Outputs["SurrogateNO"]);
            }
            catch { }

            try
            {
                SurrogateName = System.Convert.ToString(Outputs["SurrogateName"]);
            }
            catch { }

            try
            {
                CommendID = System.Convert.ToInt64(Outputs["CommendID"]);
            }
            catch { }

            try
            {
                CommendCustomerNO = System.Convert.ToString(Outputs["CommendCustomerNO"]);
            }
            catch { }

            try
            {
                CommendCustomerName = System.Convert.ToString(Outputs["CommendCustomerName"]);
            }
            catch { }

            try
            {
                ParentID = System.Convert.ToInt64(Outputs["ParentID"]);
            }
            catch { }

            try
            {
                ParentCustomerNO = System.Convert.ToString(Outputs["ParentCustomerNO"]);
            }
            catch { }

            try
            {
                ParentCustomerName = System.Convert.ToString(Outputs["ParentCustomerName"]);
            }
            catch { }

            try
            {
                LR = System.Convert.ToInt16(Outputs["LR"]);
            }
            catch { }

            try
            {
                isLock = System.Convert.ToBoolean(Outputs["isLock"]);
            }
            catch { }

            try
            {
                isActivation = System.Convert.ToBoolean(Outputs["isActivation"]);
            }
            catch { }

            try
            {
                IsSurrogate = System.Convert.ToBoolean(Outputs["IsSurrogate"]);
            }
            catch { }

            try
            {
                Balance = System.Convert.ToDouble(Outputs["Balance"]);
            }
            catch { }

            try
            {
                Freeze = System.Convert.ToDouble(Outputs["Freeze"]);
            }
            catch { }

            try
            {
                Earning = System.Convert.ToDouble(Outputs["Earning"]);
            }
            catch { }

            try
            {
                EarningBalance = System.Convert.ToDouble(Outputs["EarningBalance"]);
            }
            catch { }

            try
            {
                EarningBalance2 = System.Convert.ToDouble(Outputs["EarningBalance2"]);
            }
            catch { }

            try
            {
                Earning2 = System.Convert.ToDouble(Outputs["Earning2"]);
            }
            catch { }

            try
            {
                Earning3 = System.Convert.ToDouble(Outputs["Earning3"]);
            }
            catch { }

            try
            {
                EarningBalance3 = System.Convert.ToDouble(Outputs["EarningBalance3"]);
            }
            catch { }

            try
            {
                FundManage = System.Convert.ToDouble(Outputs["FundManage"]);
            }
            catch { }

            try
            {
                Tax = System.Convert.ToDouble(Outputs["Tax"]);
            }
            catch { }

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                BV = System.Convert.ToDouble(Outputs["BV"]);
            }
            catch { }

            try
            {
                UpVipDate = System.Convert.ToDateTime(Outputs["UpVipDate"]);
            }
            catch { }

            try
            {
                LastLoginTime = System.Convert.ToDateTime(Outputs["LastLoginTime"]);
            }
            catch { }

            try
            {
                LastLoginIP = System.Convert.ToString(Outputs["LastLoginIP"]);
            }
            catch { }

            try
            {
                LoginNum = System.Convert.ToInt32(Outputs["LoginNum"]);
            }
            catch { }

            try
            {
                OwnerCustomerID = System.Convert.ToInt64(Outputs["OwnerCustomerID"]);
            }
            catch { }

            try
            {
                isOwnerCustomer = System.Convert.ToBoolean(Outputs["isOwnerCustomer"]);
            }
            catch { }

            try
            {
                isShopAgent = System.Convert.ToBoolean(Outputs["isShopAgent"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetCustomerInformationByName(string CustomerName, long ShopSiteID, ref long CustomerID, ref string CustomerNo, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int ProvinceID, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double FundManage, ref double Tax, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_GetCustomerInformationByName(ref ds, CustomerName, ShopSiteID, ref CustomerID, ref CustomerNo, ref CustomerTypeID, ref CustomerTypeName, ref IsAward, ref Password1, ref Password2, ref Tel, ref Mobile, ref QQ, ref Email, ref PostCode, ref ProvinceID, ref CityID, ref Province, ref City, ref Address, ref Fax, ref Other, ref Sex, ref Birthday, ref CertTypeID, ref CertTypeName, ref CertNo, ref BankTypeID, ref BankTypeName, ref BankNameDetail, ref BankCardNumber, ref BankCustName, ref AlipayNo, ref DeptID, ref DeparmenttName, ref RegisterOperID, ref RegisterCustomerNO, ref RegisterCustomerName, ref RegisterDate, ref VerfyOperID, ref VerfyCustomerNO, ref VerfyCustomerName, ref VerfyDate, ref Status, ref State, ref Remark, ref ShopNo, ref ShopName, ref ShopID, ref RegisterShopID, ref RegisterShopNO, ref RegisterShopName, ref SurrogateID, ref SurrogateNO, ref SurrogateName, ref CommendID, ref CommendCustomerNO, ref CommendCustomerName, ref ParentID, ref ParentCustomerNO, ref ParentCustomerName, ref LR, ref isLock, ref isActivation, ref IsSurrogate, ref Balance, ref Freeze, ref Earning, ref EarningBalance, ref EarningBalance2, ref Earning2, ref Earning3, ref EarningBalance3, ref FundManage, ref Tax, ref PV, ref BV, ref UpVipDate, ref LastLoginTime, ref LastLoginIP, ref LoginNum, ref OwnerCustomerID, ref isOwnerCustomer, ref isShopAgent, ref ReturnDescription);
        }

        public static int P_GetCustomerInformationByName(ref DataSet ds, string CustomerName, long ShopSiteID, ref long CustomerID, ref string CustomerNo, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int ProvinceID, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double FundManage, ref double Tax, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerInformationByName", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerName),
                new MSSQL.Parameter("ShopSiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopSiteID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("CustomerNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerNo),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CustomerTypeID),
                new MSSQL.Parameter("CustomerTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerTypeName),
                new MSSQL.Parameter("IsAward", SqlDbType.Bit, 1, ParameterDirection.Output, IsAward),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 50, ParameterDirection.Output, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 50, ParameterDirection.Output, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 50, ParameterDirection.Output, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 50, ParameterDirection.Output, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 50, ParameterDirection.Output, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 50, ParameterDirection.Output, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 50, ParameterDirection.Output, PostCode),
                new MSSQL.Parameter("ProvinceID", SqlDbType.Int, 4, ParameterDirection.Output, ProvinceID),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 4, ParameterDirection.Output, CityID),
                new MSSQL.Parameter("Province", SqlDbType.VarChar, 50, ParameterDirection.Output, Province),
                new MSSQL.Parameter("City", SqlDbType.VarChar, 50, ParameterDirection.Output, City),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 50, ParameterDirection.Output, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 50, ParameterDirection.Output, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 50, ParameterDirection.Output, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 50, ParameterDirection.Output, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 8, ParameterDirection.Output, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CertTypeID),
                new MSSQL.Parameter("CertTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CertTypeName),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 4, ParameterDirection.Output, BankTypeID),
                new MSSQL.Parameter("BankTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankTypeName),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 50, ParameterDirection.Output, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCustName),
                new MSSQL.Parameter("AlipayNo", SqlDbType.VarChar, 50, ParameterDirection.Output, AlipayNo),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 4, ParameterDirection.Output, DeptID),
                new MSSQL.Parameter("DeparmenttName", SqlDbType.VarChar, 50, ParameterDirection.Output, DeparmenttName),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterOperID),
                new MSSQL.Parameter("RegisterCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerNO),
                new MSSQL.Parameter("RegisterCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerName),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 8, ParameterDirection.Output, RegisterDate),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, VerfyOperID),
                new MSSQL.Parameter("VerfyCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerNO),
                new MSSQL.Parameter("VerfyCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerName),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 8, ParameterDirection.Output, VerfyDate),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 1, ParameterDirection.Output, Status),
                new MSSQL.Parameter("State", SqlDbType.VarChar, 50, ParameterDirection.Output, State),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 255, ParameterDirection.Output, Remark),
                new MSSQL.Parameter("ShopNo", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopNo),
                new MSSQL.Parameter("ShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopName),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterShopID),
                new MSSQL.Parameter("RegisterShopNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopNO),
                new MSSQL.Parameter("RegisterShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopName),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 8, ParameterDirection.Output, SurrogateID),
                new MSSQL.Parameter("SurrogateNO", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateNO),
                new MSSQL.Parameter("SurrogateName", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateName),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 8, ParameterDirection.Output, CommendID),
                new MSSQL.Parameter("CommendCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerNO),
                new MSSQL.Parameter("CommendCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerName),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 8, ParameterDirection.Output, ParentID),
                new MSSQL.Parameter("ParentCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerNO),
                new MSSQL.Parameter("ParentCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerName),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 1, ParameterDirection.Output, LR),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 1, ParameterDirection.Output, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 1, ParameterDirection.Output, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 1, ParameterDirection.Output, IsSurrogate),
                new MSSQL.Parameter("Balance", SqlDbType.Money, 8, ParameterDirection.Output, Balance),
                new MSSQL.Parameter("Freeze", SqlDbType.Money, 8, ParameterDirection.Output, Freeze),
                new MSSQL.Parameter("Earning", SqlDbType.Money, 8, ParameterDirection.Output, Earning),
                new MSSQL.Parameter("EarningBalance", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance),
                new MSSQL.Parameter("EarningBalance2", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance2),
                new MSSQL.Parameter("Earning2", SqlDbType.Money, 8, ParameterDirection.Output, Earning2),
                new MSSQL.Parameter("Earning3", SqlDbType.Money, 8, ParameterDirection.Output, Earning3),
                new MSSQL.Parameter("EarningBalance3", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance3),
                new MSSQL.Parameter("FundManage", SqlDbType.Money, 8, ParameterDirection.Output, FundManage),
                new MSSQL.Parameter("Tax", SqlDbType.Money, 8, ParameterDirection.Output, Tax),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 8, ParameterDirection.Output, BV),
                new MSSQL.Parameter("UpVipDate", SqlDbType.DateTime, 8, ParameterDirection.Output, UpVipDate),
                new MSSQL.Parameter("LastLoginTime", SqlDbType.DateTime, 8, ParameterDirection.Output, LastLoginTime),
                new MSSQL.Parameter("LastLoginIP", SqlDbType.VarChar, 50, ParameterDirection.Output, LastLoginIP),
                new MSSQL.Parameter("LoginNum", SqlDbType.Int, 4, ParameterDirection.Output, LoginNum),
                new MSSQL.Parameter("OwnerCustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, OwnerCustomerID),
                new MSSQL.Parameter("isOwnerCustomer", SqlDbType.Bit, 1, ParameterDirection.Output, isOwnerCustomer),
                new MSSQL.Parameter("isShopAgent", SqlDbType.Bit, 1, ParameterDirection.Output, isShopAgent),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                CustomerNo = System.Convert.ToString(Outputs["CustomerNo"]);
            }
            catch { }

            try
            {
                CustomerTypeID = System.Convert.ToInt16(Outputs["CustomerTypeID"]);
            }
            catch { }

            try
            {
                CustomerTypeName = System.Convert.ToString(Outputs["CustomerTypeName"]);
            }
            catch { }

            try
            {
                IsAward = System.Convert.ToBoolean(Outputs["IsAward"]);
            }
            catch { }

            try
            {
                Password1 = System.Convert.ToString(Outputs["Password1"]);
            }
            catch { }

            try
            {
                Password2 = System.Convert.ToString(Outputs["Password2"]);
            }
            catch { }

            try
            {
                Tel = System.Convert.ToString(Outputs["Tel"]);
            }
            catch { }

            try
            {
                Mobile = System.Convert.ToString(Outputs["Mobile"]);
            }
            catch { }

            try
            {
                QQ = System.Convert.ToString(Outputs["QQ"]);
            }
            catch { }

            try
            {
                Email = System.Convert.ToString(Outputs["Email"]);
            }
            catch { }

            try
            {
                PostCode = System.Convert.ToString(Outputs["PostCode"]);
            }
            catch { }

            try
            {
                ProvinceID = System.Convert.ToInt32(Outputs["ProvinceID"]);
            }
            catch { }

            try
            {
                CityID = System.Convert.ToInt32(Outputs["CityID"]);
            }
            catch { }

            try
            {
                Province = System.Convert.ToString(Outputs["Province"]);
            }
            catch { }

            try
            {
                City = System.Convert.ToString(Outputs["City"]);
            }
            catch { }

            try
            {
                Address = System.Convert.ToString(Outputs["Address"]);
            }
            catch { }

            try
            {
                Fax = System.Convert.ToString(Outputs["Fax"]);
            }
            catch { }

            try
            {
                Other = System.Convert.ToString(Outputs["Other"]);
            }
            catch { }

            try
            {
                Sex = System.Convert.ToString(Outputs["Sex"]);
            }
            catch { }

            try
            {
                Birthday = System.Convert.ToDateTime(Outputs["Birthday"]);
            }
            catch { }

            try
            {
                CertTypeID = System.Convert.ToInt16(Outputs["CertTypeID"]);
            }
            catch { }

            try
            {
                CertTypeName = System.Convert.ToString(Outputs["CertTypeName"]);
            }
            catch { }

            try
            {
                CertNo = System.Convert.ToString(Outputs["CertNo"]);
            }
            catch { }

            try
            {
                BankTypeID = System.Convert.ToInt32(Outputs["BankTypeID"]);
            }
            catch { }

            try
            {
                BankTypeName = System.Convert.ToString(Outputs["BankTypeName"]);
            }
            catch { }

            try
            {
                BankNameDetail = System.Convert.ToString(Outputs["BankNameDetail"]);
            }
            catch { }

            try
            {
                BankCardNumber = System.Convert.ToString(Outputs["BankCardNumber"]);
            }
            catch { }

            try
            {
                BankCustName = System.Convert.ToString(Outputs["BankCustName"]);
            }
            catch { }

            try
            {
                AlipayNo = System.Convert.ToString(Outputs["AlipayNo"]);
            }
            catch { }

            try
            {
                DeptID = System.Convert.ToInt32(Outputs["DeptID"]);
            }
            catch { }

            try
            {
                DeparmenttName = System.Convert.ToString(Outputs["DeparmenttName"]);
            }
            catch { }

            try
            {
                RegisterOperID = System.Convert.ToInt64(Outputs["RegisterOperID"]);
            }
            catch { }

            try
            {
                RegisterCustomerNO = System.Convert.ToString(Outputs["RegisterCustomerNO"]);
            }
            catch { }

            try
            {
                RegisterCustomerName = System.Convert.ToString(Outputs["RegisterCustomerName"]);
            }
            catch { }

            try
            {
                RegisterDate = System.Convert.ToDateTime(Outputs["RegisterDate"]);
            }
            catch { }

            try
            {
                VerfyOperID = System.Convert.ToInt64(Outputs["VerfyOperID"]);
            }
            catch { }

            try
            {
                VerfyCustomerNO = System.Convert.ToString(Outputs["VerfyCustomerNO"]);
            }
            catch { }

            try
            {
                VerfyCustomerName = System.Convert.ToString(Outputs["VerfyCustomerName"]);
            }
            catch { }

            try
            {
                VerfyDate = System.Convert.ToDateTime(Outputs["VerfyDate"]);
            }
            catch { }

            try
            {
                Status = System.Convert.ToInt16(Outputs["Status"]);
            }
            catch { }

            try
            {
                State = System.Convert.ToString(Outputs["State"]);
            }
            catch { }

            try
            {
                Remark = System.Convert.ToString(Outputs["Remark"]);
            }
            catch { }

            try
            {
                ShopNo = System.Convert.ToString(Outputs["ShopNo"]);
            }
            catch { }

            try
            {
                ShopName = System.Convert.ToString(Outputs["ShopName"]);
            }
            catch { }

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                RegisterShopID = System.Convert.ToInt64(Outputs["RegisterShopID"]);
            }
            catch { }

            try
            {
                RegisterShopNO = System.Convert.ToString(Outputs["RegisterShopNO"]);
            }
            catch { }

            try
            {
                RegisterShopName = System.Convert.ToString(Outputs["RegisterShopName"]);
            }
            catch { }

            try
            {
                SurrogateID = System.Convert.ToInt64(Outputs["SurrogateID"]);
            }
            catch { }

            try
            {
                SurrogateNO = System.Convert.ToString(Outputs["SurrogateNO"]);
            }
            catch { }

            try
            {
                SurrogateName = System.Convert.ToString(Outputs["SurrogateName"]);
            }
            catch { }

            try
            {
                CommendID = System.Convert.ToInt64(Outputs["CommendID"]);
            }
            catch { }

            try
            {
                CommendCustomerNO = System.Convert.ToString(Outputs["CommendCustomerNO"]);
            }
            catch { }

            try
            {
                CommendCustomerName = System.Convert.ToString(Outputs["CommendCustomerName"]);
            }
            catch { }

            try
            {
                ParentID = System.Convert.ToInt64(Outputs["ParentID"]);
            }
            catch { }

            try
            {
                ParentCustomerNO = System.Convert.ToString(Outputs["ParentCustomerNO"]);
            }
            catch { }

            try
            {
                ParentCustomerName = System.Convert.ToString(Outputs["ParentCustomerName"]);
            }
            catch { }

            try
            {
                LR = System.Convert.ToInt16(Outputs["LR"]);
            }
            catch { }

            try
            {
                isLock = System.Convert.ToBoolean(Outputs["isLock"]);
            }
            catch { }

            try
            {
                isActivation = System.Convert.ToBoolean(Outputs["isActivation"]);
            }
            catch { }

            try
            {
                IsSurrogate = System.Convert.ToBoolean(Outputs["IsSurrogate"]);
            }
            catch { }

            try
            {
                Balance = System.Convert.ToDouble(Outputs["Balance"]);
            }
            catch { }

            try
            {
                Freeze = System.Convert.ToDouble(Outputs["Freeze"]);
            }
            catch { }

            try
            {
                Earning = System.Convert.ToDouble(Outputs["Earning"]);
            }
            catch { }

            try
            {
                EarningBalance = System.Convert.ToDouble(Outputs["EarningBalance"]);
            }
            catch { }

            try
            {
                EarningBalance2 = System.Convert.ToDouble(Outputs["EarningBalance2"]);
            }
            catch { }

            try
            {
                Earning2 = System.Convert.ToDouble(Outputs["Earning2"]);
            }
            catch { }

            try
            {
                Earning3 = System.Convert.ToDouble(Outputs["Earning3"]);
            }
            catch { }

            try
            {
                EarningBalance3 = System.Convert.ToDouble(Outputs["EarningBalance3"]);
            }
            catch { }

            try
            {
                FundManage = System.Convert.ToDouble(Outputs["FundManage"]);
            }
            catch { }

            try
            {
                Tax = System.Convert.ToDouble(Outputs["Tax"]);
            }
            catch { }

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                BV = System.Convert.ToDouble(Outputs["BV"]);
            }
            catch { }

            try
            {
                UpVipDate = System.Convert.ToDateTime(Outputs["UpVipDate"]);
            }
            catch { }

            try
            {
                LastLoginTime = System.Convert.ToDateTime(Outputs["LastLoginTime"]);
            }
            catch { }

            try
            {
                LastLoginIP = System.Convert.ToString(Outputs["LastLoginIP"]);
            }
            catch { }

            try
            {
                LoginNum = System.Convert.ToInt32(Outputs["LoginNum"]);
            }
            catch { }

            try
            {
                OwnerCustomerID = System.Convert.ToInt64(Outputs["OwnerCustomerID"]);
            }
            catch { }

            try
            {
                isOwnerCustomer = System.Convert.ToBoolean(Outputs["isOwnerCustomer"]);
            }
            catch { }

            try
            {
                isShopAgent = System.Convert.ToBoolean(Outputs["isShopAgent"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_DelAllocate_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelAllocate_Master(ref ds, ID);
        }

        public static int P_Shop_DelAllocate_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelAllocate_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_CheckAllocate(long ID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckAllocate(ref ds, ID, VerfyOperID);
        }

        public static int P_Shop_CheckAllocate(ref DataSet ds, long ID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckAllocate", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_GetCustomerInformationByID(long CustomerID, long ShopSiteID, ref string CustomerNO, ref string CustomerName, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int ProvinceID, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double FundManage, ref double Tax, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_GetCustomerInformationByID(ref ds, CustomerID, ShopSiteID, ref CustomerNO, ref CustomerName, ref CustomerTypeID, ref CustomerTypeName, ref IsAward, ref Password1, ref Password2, ref Tel, ref Mobile, ref QQ, ref Email, ref PostCode, ref ProvinceID, ref CityID, ref Province, ref City, ref Address, ref Fax, ref Other, ref Sex, ref Birthday, ref CertTypeID, ref CertTypeName, ref CertNo, ref BankTypeID, ref BankTypeName, ref BankNameDetail, ref BankCardNumber, ref BankCustName, ref AlipayNo, ref DeptID, ref DeparmenttName, ref RegisterOperID, ref RegisterCustomerNO, ref RegisterCustomerName, ref RegisterDate, ref VerfyOperID, ref VerfyCustomerNO, ref VerfyCustomerName, ref VerfyDate, ref Status, ref State, ref Remark, ref ShopNo, ref ShopName, ref ShopID, ref RegisterShopID, ref RegisterShopNO, ref RegisterShopName, ref SurrogateID, ref SurrogateNO, ref SurrogateName, ref CommendID, ref CommendCustomerNO, ref CommendCustomerName, ref ParentID, ref ParentCustomerNO, ref ParentCustomerName, ref LR, ref isLock, ref isActivation, ref IsSurrogate, ref Balance, ref Freeze, ref Earning, ref EarningBalance, ref EarningBalance2, ref Earning2, ref Earning3, ref EarningBalance3, ref FundManage, ref Tax, ref PV, ref BV, ref UpVipDate, ref LastLoginTime, ref LastLoginIP, ref LoginNum, ref OwnerCustomerID, ref isOwnerCustomer, ref isShopAgent, ref ReturnDescription);
        }

        public static int P_GetCustomerInformationByID(ref DataSet ds, long CustomerID, long ShopSiteID, ref string CustomerNO, ref string CustomerName, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int ProvinceID, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double FundManage, ref double Tax, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetCustomerInformationByID", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("ShopSiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopSiteID),
                new MSSQL.Parameter("CustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerNO),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CustomerTypeID),
                new MSSQL.Parameter("CustomerTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerTypeName),
                new MSSQL.Parameter("IsAward", SqlDbType.Bit, 1, ParameterDirection.Output, IsAward),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 50, ParameterDirection.Output, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 50, ParameterDirection.Output, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 50, ParameterDirection.Output, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 50, ParameterDirection.Output, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 50, ParameterDirection.Output, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 50, ParameterDirection.Output, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 50, ParameterDirection.Output, PostCode),
                new MSSQL.Parameter("ProvinceID", SqlDbType.Int, 4, ParameterDirection.Output, ProvinceID),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 4, ParameterDirection.Output, CityID),
                new MSSQL.Parameter("Province", SqlDbType.VarChar, 50, ParameterDirection.Output, Province),
                new MSSQL.Parameter("City", SqlDbType.VarChar, 50, ParameterDirection.Output, City),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 50, ParameterDirection.Output, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 50, ParameterDirection.Output, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 50, ParameterDirection.Output, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 50, ParameterDirection.Output, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 8, ParameterDirection.Output, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CertTypeID),
                new MSSQL.Parameter("CertTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CertTypeName),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 4, ParameterDirection.Output, BankTypeID),
                new MSSQL.Parameter("BankTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankTypeName),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 50, ParameterDirection.Output, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCustName),
                new MSSQL.Parameter("AlipayNo", SqlDbType.VarChar, 50, ParameterDirection.Output, AlipayNo),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 4, ParameterDirection.Output, DeptID),
                new MSSQL.Parameter("DeparmenttName", SqlDbType.VarChar, 50, ParameterDirection.Output, DeparmenttName),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterOperID),
                new MSSQL.Parameter("RegisterCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerNO),
                new MSSQL.Parameter("RegisterCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerName),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 8, ParameterDirection.Output, RegisterDate),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, VerfyOperID),
                new MSSQL.Parameter("VerfyCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerNO),
                new MSSQL.Parameter("VerfyCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerName),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 8, ParameterDirection.Output, VerfyDate),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 1, ParameterDirection.Output, Status),
                new MSSQL.Parameter("State", SqlDbType.VarChar, 50, ParameterDirection.Output, State),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 255, ParameterDirection.Output, Remark),
                new MSSQL.Parameter("ShopNo", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopNo),
                new MSSQL.Parameter("ShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopName),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterShopID),
                new MSSQL.Parameter("RegisterShopNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopNO),
                new MSSQL.Parameter("RegisterShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopName),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 8, ParameterDirection.Output, SurrogateID),
                new MSSQL.Parameter("SurrogateNO", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateNO),
                new MSSQL.Parameter("SurrogateName", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateName),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 8, ParameterDirection.Output, CommendID),
                new MSSQL.Parameter("CommendCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerNO),
                new MSSQL.Parameter("CommendCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerName),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 8, ParameterDirection.Output, ParentID),
                new MSSQL.Parameter("ParentCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerNO),
                new MSSQL.Parameter("ParentCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerName),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 1, ParameterDirection.Output, LR),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 1, ParameterDirection.Output, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 1, ParameterDirection.Output, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 1, ParameterDirection.Output, IsSurrogate),
                new MSSQL.Parameter("Balance", SqlDbType.Money, 8, ParameterDirection.Output, Balance),
                new MSSQL.Parameter("Freeze", SqlDbType.Money, 8, ParameterDirection.Output, Freeze),
                new MSSQL.Parameter("Earning", SqlDbType.Money, 8, ParameterDirection.Output, Earning),
                new MSSQL.Parameter("EarningBalance", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance),
                new MSSQL.Parameter("EarningBalance2", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance2),
                new MSSQL.Parameter("Earning2", SqlDbType.Money, 8, ParameterDirection.Output, Earning2),
                new MSSQL.Parameter("Earning3", SqlDbType.Money, 8, ParameterDirection.Output, Earning3),
                new MSSQL.Parameter("EarningBalance3", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance3),
                new MSSQL.Parameter("FundManage", SqlDbType.Money, 8, ParameterDirection.Output, FundManage),
                new MSSQL.Parameter("Tax", SqlDbType.Money, 8, ParameterDirection.Output, Tax),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 8, ParameterDirection.Output, BV),
                new MSSQL.Parameter("UpVipDate", SqlDbType.DateTime, 8, ParameterDirection.Output, UpVipDate),
                new MSSQL.Parameter("LastLoginTime", SqlDbType.DateTime, 8, ParameterDirection.Output, LastLoginTime),
                new MSSQL.Parameter("LastLoginIP", SqlDbType.VarChar, 50, ParameterDirection.Output, LastLoginIP),
                new MSSQL.Parameter("LoginNum", SqlDbType.Int, 4, ParameterDirection.Output, LoginNum),
                new MSSQL.Parameter("OwnerCustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, OwnerCustomerID),
                new MSSQL.Parameter("isOwnerCustomer", SqlDbType.Bit, 1, ParameterDirection.Output, isOwnerCustomer),
                new MSSQL.Parameter("isShopAgent", SqlDbType.Bit, 1, ParameterDirection.Output, isShopAgent),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                CustomerNO = System.Convert.ToString(Outputs["CustomerNO"]);
            }
            catch { }

            try
            {
                CustomerName = System.Convert.ToString(Outputs["CustomerName"]);
            }
            catch { }

            try
            {
                CustomerTypeID = System.Convert.ToInt16(Outputs["CustomerTypeID"]);
            }
            catch { }

            try
            {
                CustomerTypeName = System.Convert.ToString(Outputs["CustomerTypeName"]);
            }
            catch { }

            try
            {
                IsAward = System.Convert.ToBoolean(Outputs["IsAward"]);
            }
            catch { }

            try
            {
                Password1 = System.Convert.ToString(Outputs["Password1"]);
            }
            catch { }

            try
            {
                Password2 = System.Convert.ToString(Outputs["Password2"]);
            }
            catch { }

            try
            {
                Tel = System.Convert.ToString(Outputs["Tel"]);
            }
            catch { }

            try
            {
                Mobile = System.Convert.ToString(Outputs["Mobile"]);
            }
            catch { }

            try
            {
                QQ = System.Convert.ToString(Outputs["QQ"]);
            }
            catch { }

            try
            {
                Email = System.Convert.ToString(Outputs["Email"]);
            }
            catch { }

            try
            {
                PostCode = System.Convert.ToString(Outputs["PostCode"]);
            }
            catch { }

            try
            {
                ProvinceID = System.Convert.ToInt32(Outputs["ProvinceID"]);
            }
            catch { }

            try
            {
                CityID = System.Convert.ToInt32(Outputs["CityID"]);
            }
            catch { }

            try
            {
                Province = System.Convert.ToString(Outputs["Province"]);
            }
            catch { }

            try
            {
                City = System.Convert.ToString(Outputs["City"]);
            }
            catch { }

            try
            {
                Address = System.Convert.ToString(Outputs["Address"]);
            }
            catch { }

            try
            {
                Fax = System.Convert.ToString(Outputs["Fax"]);
            }
            catch { }

            try
            {
                Other = System.Convert.ToString(Outputs["Other"]);
            }
            catch { }

            try
            {
                Sex = System.Convert.ToString(Outputs["Sex"]);
            }
            catch { }

            try
            {
                Birthday = System.Convert.ToDateTime(Outputs["Birthday"]);
            }
            catch { }

            try
            {
                CertTypeID = System.Convert.ToInt16(Outputs["CertTypeID"]);
            }
            catch { }

            try
            {
                CertTypeName = System.Convert.ToString(Outputs["CertTypeName"]);
            }
            catch { }

            try
            {
                CertNo = System.Convert.ToString(Outputs["CertNo"]);
            }
            catch { }

            try
            {
                BankTypeID = System.Convert.ToInt32(Outputs["BankTypeID"]);
            }
            catch { }

            try
            {
                BankTypeName = System.Convert.ToString(Outputs["BankTypeName"]);
            }
            catch { }

            try
            {
                BankNameDetail = System.Convert.ToString(Outputs["BankNameDetail"]);
            }
            catch { }

            try
            {
                BankCardNumber = System.Convert.ToString(Outputs["BankCardNumber"]);
            }
            catch { }

            try
            {
                BankCustName = System.Convert.ToString(Outputs["BankCustName"]);
            }
            catch { }

            try
            {
                AlipayNo = System.Convert.ToString(Outputs["AlipayNo"]);
            }
            catch { }

            try
            {
                DeptID = System.Convert.ToInt32(Outputs["DeptID"]);
            }
            catch { }

            try
            {
                DeparmenttName = System.Convert.ToString(Outputs["DeparmenttName"]);
            }
            catch { }

            try
            {
                RegisterOperID = System.Convert.ToInt64(Outputs["RegisterOperID"]);
            }
            catch { }

            try
            {
                RegisterCustomerNO = System.Convert.ToString(Outputs["RegisterCustomerNO"]);
            }
            catch { }

            try
            {
                RegisterCustomerName = System.Convert.ToString(Outputs["RegisterCustomerName"]);
            }
            catch { }

            try
            {
                RegisterDate = System.Convert.ToDateTime(Outputs["RegisterDate"]);
            }
            catch { }

            try
            {
                VerfyOperID = System.Convert.ToInt64(Outputs["VerfyOperID"]);
            }
            catch { }

            try
            {
                VerfyCustomerNO = System.Convert.ToString(Outputs["VerfyCustomerNO"]);
            }
            catch { }

            try
            {
                VerfyCustomerName = System.Convert.ToString(Outputs["VerfyCustomerName"]);
            }
            catch { }

            try
            {
                VerfyDate = System.Convert.ToDateTime(Outputs["VerfyDate"]);
            }
            catch { }

            try
            {
                Status = System.Convert.ToInt16(Outputs["Status"]);
            }
            catch { }

            try
            {
                State = System.Convert.ToString(Outputs["State"]);
            }
            catch { }

            try
            {
                Remark = System.Convert.ToString(Outputs["Remark"]);
            }
            catch { }

            try
            {
                ShopNo = System.Convert.ToString(Outputs["ShopNo"]);
            }
            catch { }

            try
            {
                ShopName = System.Convert.ToString(Outputs["ShopName"]);
            }
            catch { }

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                RegisterShopID = System.Convert.ToInt64(Outputs["RegisterShopID"]);
            }
            catch { }

            try
            {
                RegisterShopNO = System.Convert.ToString(Outputs["RegisterShopNO"]);
            }
            catch { }

            try
            {
                RegisterShopName = System.Convert.ToString(Outputs["RegisterShopName"]);
            }
            catch { }

            try
            {
                SurrogateID = System.Convert.ToInt64(Outputs["SurrogateID"]);
            }
            catch { }

            try
            {
                SurrogateNO = System.Convert.ToString(Outputs["SurrogateNO"]);
            }
            catch { }

            try
            {
                SurrogateName = System.Convert.ToString(Outputs["SurrogateName"]);
            }
            catch { }

            try
            {
                CommendID = System.Convert.ToInt64(Outputs["CommendID"]);
            }
            catch { }

            try
            {
                CommendCustomerNO = System.Convert.ToString(Outputs["CommendCustomerNO"]);
            }
            catch { }

            try
            {
                CommendCustomerName = System.Convert.ToString(Outputs["CommendCustomerName"]);
            }
            catch { }

            try
            {
                ParentID = System.Convert.ToInt64(Outputs["ParentID"]);
            }
            catch { }

            try
            {
                ParentCustomerNO = System.Convert.ToString(Outputs["ParentCustomerNO"]);
            }
            catch { }

            try
            {
                ParentCustomerName = System.Convert.ToString(Outputs["ParentCustomerName"]);
            }
            catch { }

            try
            {
                LR = System.Convert.ToInt16(Outputs["LR"]);
            }
            catch { }

            try
            {
                isLock = System.Convert.ToBoolean(Outputs["isLock"]);
            }
            catch { }

            try
            {
                isActivation = System.Convert.ToBoolean(Outputs["isActivation"]);
            }
            catch { }

            try
            {
                IsSurrogate = System.Convert.ToBoolean(Outputs["IsSurrogate"]);
            }
            catch { }

            try
            {
                Balance = System.Convert.ToDouble(Outputs["Balance"]);
            }
            catch { }

            try
            {
                Freeze = System.Convert.ToDouble(Outputs["Freeze"]);
            }
            catch { }

            try
            {
                Earning = System.Convert.ToDouble(Outputs["Earning"]);
            }
            catch { }

            try
            {
                EarningBalance = System.Convert.ToDouble(Outputs["EarningBalance"]);
            }
            catch { }

            try
            {
                EarningBalance2 = System.Convert.ToDouble(Outputs["EarningBalance2"]);
            }
            catch { }

            try
            {
                Earning2 = System.Convert.ToDouble(Outputs["Earning2"]);
            }
            catch { }

            try
            {
                Earning3 = System.Convert.ToDouble(Outputs["Earning3"]);
            }
            catch { }

            try
            {
                EarningBalance3 = System.Convert.ToDouble(Outputs["EarningBalance3"]);
            }
            catch { }

            try
            {
                FundManage = System.Convert.ToDouble(Outputs["FundManage"]);
            }
            catch { }

            try
            {
                Tax = System.Convert.ToDouble(Outputs["Tax"]);
            }
            catch { }

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                BV = System.Convert.ToDouble(Outputs["BV"]);
            }
            catch { }

            try
            {
                UpVipDate = System.Convert.ToDateTime(Outputs["UpVipDate"]);
            }
            catch { }

            try
            {
                LastLoginTime = System.Convert.ToDateTime(Outputs["LastLoginTime"]);
            }
            catch { }

            try
            {
                LastLoginIP = System.Convert.ToString(Outputs["LastLoginIP"]);
            }
            catch { }

            try
            {
                LoginNum = System.Convert.ToInt32(Outputs["LoginNum"]);
            }
            catch { }

            try
            {
                OwnerCustomerID = System.Convert.ToInt64(Outputs["OwnerCustomerID"]);
            }
            catch { }

            try
            {
                isOwnerCustomer = System.Convert.ToBoolean(Outputs["isOwnerCustomer"]);
            }
            catch { }

            try
            {
                isShopAgent = System.Convert.ToBoolean(Outputs["isShopAgent"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_DelLoss_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelLoss_Master(ref ds, ID);
        }

        public static int P_Shop_DelLoss_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelLoss_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_GetOneNodeForCustomer(long CustomerID, int LR, ref long NetID)
        {
            DataSet ds = null;

            return P_GetOneNodeForCustomer(ref ds, CustomerID, LR, ref NetID);
        }

        public static int P_GetOneNodeForCustomer(ref DataSet ds, long CustomerID, int LR, ref long NetID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetOneNodeForCustomer", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("LR", SqlDbType.Int, 0, ParameterDirection.Input, LR),
                new MSSQL.Parameter("NetID", SqlDbType.BigInt, 8, ParameterDirection.Output, NetID)
                );

            try
            {
                NetID = System.Convert.ToInt64(Outputs["NetID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_EditLossDetail(long ID, long LossID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditLossDetail(ref ds, ID, LossID, GoodID, Amount);
        }

        public static int P_Shop_EditLossDetail(ref DataSet ds, long ID, long LossID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditLossDetail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("LossID", SqlDbType.BigInt, 0, ParameterDirection.Input, LossID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_Shop_DelBackGood_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelBackGood_Master(ref ds, ID);
        }

        public static int P_Shop_DelBackGood_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelBackGood_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_CheckLoss(long ID, long VerfyOperID, short LossType)
        {
            DataSet ds = null;

            return P_Shop_CheckLoss(ref ds, ID, VerfyOperID, LossType);
        }

        public static int P_Shop_CheckLoss(ref DataSet ds, long ID, long VerfyOperID, short LossType)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckLoss", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID),
                new MSSQL.Parameter("LossType", SqlDbType.TinyInt, 0, ParameterDirection.Input, LossType)
                );

            return CallResult;
        }

        public static int P_DistillEarning7(int DistillType, long Earning7ID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_DistillEarning7(ref ds, DistillType, Earning7ID, ref ReturnDescription);
        }

        public static int P_DistillEarning7(ref DataSet ds, int DistillType, long Earning7ID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DistillEarning7", ref ds, ref Outputs,
                new MSSQL.Parameter("DistillType", SqlDbType.Int, 0, ParameterDirection.Input, DistillType),
                new MSSQL.Parameter("Earning7ID", SqlDbType.BigInt, 0, ParameterDirection.Input, Earning7ID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_SetOptionBinary(string Key, byte[] Value, ref string RetrunDescription)
        {
            DataSet ds = null;

            return P_SetOptionBinary(ref ds, Key, Value, ref RetrunDescription);
        }

        public static int P_SetOptionBinary(ref DataSet ds, string Key, byte[] Value, ref string RetrunDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_SetOptionBinary", ref ds, ref Outputs,
                new MSSQL.Parameter("Key", SqlDbType.VarChar, 0, ParameterDirection.Input, Key),
                new MSSQL.Parameter("Value", SqlDbType.Image, 0, ParameterDirection.Input, Value),
                new MSSQL.Parameter("RetrunDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, RetrunDescription)
                );

            try
            {
                RetrunDescription = System.Convert.ToString(Outputs["RetrunDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Earning6(DateTime DateTime)
        {
            DataSet ds = null;

            return P_Earning6(ref ds, DateTime);
        }

        public static int P_Earning6(ref DataSet ds, DateTime DateTime)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Earning6", ref ds, ref Outputs,
                new MSSQL.Parameter("DateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, DateTime)
                );

            return CallResult;
        }

        public static int P_Shop_CheckBackGood(long ID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckBackGood(ref ds, ID, VerfyOperID);
        }

        public static int P_Shop_CheckBackGood(ref DataSet ds, long ID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckBackGood", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_DistillEarning6(int DistillType, long Earning6ID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_DistillEarning6(ref ds, DistillType, Earning6ID, ref ReturnDescription);
        }

        public static int P_DistillEarning6(ref DataSet ds, int DistillType, long Earning6ID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DistillEarning6", ref ds, ref Outputs,
                new MSSQL.Parameter("DistillType", SqlDbType.Int, 0, ParameterDirection.Input, DistillType),
                new MSSQL.Parameter("Earning6ID", SqlDbType.BigInt, 0, ParameterDirection.Input, Earning6ID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Earning5(DateTime DateTime)
        {
            DataSet ds = null;

            return P_Earning5(ref ds, DateTime);
        }

        public static int P_Earning5(ref DataSet ds, DateTime DateTime)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Earning5", ref ds, ref Outputs,
                new MSSQL.Parameter("DateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, DateTime)
                );

            return CallResult;
        }

        public static int P_Shop_DelSales_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelSales_Master(ref ds, ID);
        }

        public static int P_Shop_DelSales_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelSales_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Login(long ShopSiteID, string CustomerNo, string InputPassword, string LoginIP, ref long CustomerID, ref string CustomerName, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_Login(ref ds, ShopSiteID, CustomerNo, InputPassword, LoginIP, ref CustomerID, ref CustomerName, ref CustomerTypeID, ref CustomerTypeName, ref IsAward, ref Password1, ref Password2, ref Tel, ref Mobile, ref QQ, ref Email, ref PostCode, ref CityID, ref Province, ref City, ref Address, ref Fax, ref Other, ref Sex, ref Birthday, ref CertTypeID, ref CertTypeName, ref CertNo, ref BankTypeID, ref BankTypeName, ref BankNameDetail, ref BankCardNumber, ref BankCustName, ref AlipayNo, ref DeptID, ref DeparmenttName, ref RegisterOperID, ref RegisterCustomerNO, ref RegisterCustomerName, ref RegisterDate, ref VerfyOperID, ref VerfyCustomerNO, ref VerfyCustomerName, ref VerfyDate, ref Status, ref State, ref Remark, ref ShopNo, ref ShopName, ref ShopID, ref RegisterShopID, ref RegisterShopNO, ref RegisterShopName, ref SurrogateID, ref SurrogateNO, ref SurrogateName, ref CommendID, ref CommendCustomerNO, ref CommendCustomerName, ref ParentID, ref ParentCustomerNO, ref ParentCustomerName, ref LR, ref isLock, ref isActivation, ref IsSurrogate, ref Balance, ref Freeze, ref Earning, ref EarningBalance, ref EarningBalance2, ref Earning2, ref Earning3, ref EarningBalance3, ref PV, ref BV, ref UpVipDate, ref LastLoginTime, ref LastLoginIP, ref LoginNum, ref OwnerCustomerID, ref isOwnerCustomer, ref isShopAgent, ref ReturnDescription);
        }

        public static int P_Login(ref DataSet ds, long ShopSiteID, string CustomerNo, string InputPassword, string LoginIP, ref long CustomerID, ref string CustomerName, ref short CustomerTypeID, ref string CustomerTypeName, ref bool IsAward, ref string Password1, ref string Password2, ref string Tel, ref string Mobile, ref string QQ, ref string Email, ref string PostCode, ref int CityID, ref string Province, ref string City, ref string Address, ref string Fax, ref string Other, ref string Sex, ref DateTime Birthday, ref short CertTypeID, ref string CertTypeName, ref string CertNo, ref int BankTypeID, ref string BankTypeName, ref string BankNameDetail, ref string BankCardNumber, ref string BankCustName, ref string AlipayNo, ref int DeptID, ref string DeparmenttName, ref long RegisterOperID, ref string RegisterCustomerNO, ref string RegisterCustomerName, ref DateTime RegisterDate, ref long VerfyOperID, ref string VerfyCustomerNO, ref string VerfyCustomerName, ref DateTime VerfyDate, ref short Status, ref string State, ref string Remark, ref string ShopNo, ref string ShopName, ref long ShopID, ref long RegisterShopID, ref string RegisterShopNO, ref string RegisterShopName, ref long SurrogateID, ref string SurrogateNO, ref string SurrogateName, ref long CommendID, ref string CommendCustomerNO, ref string CommendCustomerName, ref long ParentID, ref string ParentCustomerNO, ref string ParentCustomerName, ref short LR, ref bool isLock, ref bool isActivation, ref bool IsSurrogate, ref double Balance, ref double Freeze, ref double Earning, ref double EarningBalance, ref double EarningBalance2, ref double Earning2, ref double Earning3, ref double EarningBalance3, ref double PV, ref double BV, ref DateTime UpVipDate, ref DateTime LastLoginTime, ref string LastLoginIP, ref int LoginNum, ref long OwnerCustomerID, ref bool isOwnerCustomer, ref bool isShopAgent, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Login", ref ds, ref Outputs,
                new MSSQL.Parameter("ShopSiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShopSiteID),
                new MSSQL.Parameter("CustomerNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerNo),
                new MSSQL.Parameter("InputPassword", SqlDbType.VarChar, 0, ParameterDirection.Input, InputPassword),
                new MSSQL.Parameter("LoginIP", SqlDbType.VarChar, 0, ParameterDirection.Input, LoginIP),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CustomerTypeID),
                new MSSQL.Parameter("CustomerTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CustomerTypeName),
                new MSSQL.Parameter("IsAward", SqlDbType.Bit, 1, ParameterDirection.Output, IsAward),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 50, ParameterDirection.Output, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 50, ParameterDirection.Output, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 50, ParameterDirection.Output, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 50, ParameterDirection.Output, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 50, ParameterDirection.Output, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 50, ParameterDirection.Output, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 50, ParameterDirection.Output, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 4, ParameterDirection.Output, CityID),
                new MSSQL.Parameter("Province", SqlDbType.VarChar, 50, ParameterDirection.Output, Province),
                new MSSQL.Parameter("City", SqlDbType.VarChar, 50, ParameterDirection.Output, City),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 50, ParameterDirection.Output, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 50, ParameterDirection.Output, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 50, ParameterDirection.Output, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 50, ParameterDirection.Output, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 8, ParameterDirection.Output, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 1, ParameterDirection.Output, CertTypeID),
                new MSSQL.Parameter("CertTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, CertTypeName),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 50, ParameterDirection.Output, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 4, ParameterDirection.Output, BankTypeID),
                new MSSQL.Parameter("BankTypeName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankTypeName),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 50, ParameterDirection.Output, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCardNumber),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 50, ParameterDirection.Output, BankCustName),
                new MSSQL.Parameter("AlipayNo", SqlDbType.VarChar, 50, ParameterDirection.Output, AlipayNo),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 4, ParameterDirection.Output, DeptID),
                new MSSQL.Parameter("DeparmenttName", SqlDbType.VarChar, 50, ParameterDirection.Output, DeparmenttName),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterOperID),
                new MSSQL.Parameter("RegisterCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerNO),
                new MSSQL.Parameter("RegisterCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterCustomerName),
                new MSSQL.Parameter("RegisterDate", SqlDbType.DateTime, 8, ParameterDirection.Output, RegisterDate),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 8, ParameterDirection.Output, VerfyOperID),
                new MSSQL.Parameter("VerfyCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerNO),
                new MSSQL.Parameter("VerfyCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, VerfyCustomerName),
                new MSSQL.Parameter("VerfyDate", SqlDbType.DateTime, 8, ParameterDirection.Output, VerfyDate),
                new MSSQL.Parameter("Status", SqlDbType.TinyInt, 1, ParameterDirection.Output, Status),
                new MSSQL.Parameter("State", SqlDbType.VarChar, 50, ParameterDirection.Output, State),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 255, ParameterDirection.Output, Remark),
                new MSSQL.Parameter("ShopNo", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopNo),
                new MSSQL.Parameter("ShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, ShopName),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, RegisterShopID),
                new MSSQL.Parameter("RegisterShopNO", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopNO),
                new MSSQL.Parameter("RegisterShopName", SqlDbType.VarChar, 50, ParameterDirection.Output, RegisterShopName),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 8, ParameterDirection.Output, SurrogateID),
                new MSSQL.Parameter("SurrogateNO", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateNO),
                new MSSQL.Parameter("SurrogateName", SqlDbType.VarChar, 50, ParameterDirection.Output, SurrogateName),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 8, ParameterDirection.Output, CommendID),
                new MSSQL.Parameter("CommendCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerNO),
                new MSSQL.Parameter("CommendCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, CommendCustomerName),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 8, ParameterDirection.Output, ParentID),
                new MSSQL.Parameter("ParentCustomerNO", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerNO),
                new MSSQL.Parameter("ParentCustomerName", SqlDbType.VarChar, 50, ParameterDirection.Output, ParentCustomerName),
                new MSSQL.Parameter("LR", SqlDbType.TinyInt, 1, ParameterDirection.Output, LR),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 1, ParameterDirection.Output, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 1, ParameterDirection.Output, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 1, ParameterDirection.Output, IsSurrogate),
                new MSSQL.Parameter("Balance", SqlDbType.Money, 8, ParameterDirection.Output, Balance),
                new MSSQL.Parameter("Freeze", SqlDbType.Money, 8, ParameterDirection.Output, Freeze),
                new MSSQL.Parameter("Earning", SqlDbType.Money, 8, ParameterDirection.Output, Earning),
                new MSSQL.Parameter("EarningBalance", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance),
                new MSSQL.Parameter("EarningBalance2", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance2),
                new MSSQL.Parameter("Earning2", SqlDbType.Money, 8, ParameterDirection.Output, Earning2),
                new MSSQL.Parameter("Earning3", SqlDbType.Money, 8, ParameterDirection.Output, Earning3),
                new MSSQL.Parameter("EarningBalance3", SqlDbType.Money, 8, ParameterDirection.Output, EarningBalance3),
                new MSSQL.Parameter("PV", SqlDbType.Money, 8, ParameterDirection.Output, PV),
                new MSSQL.Parameter("BV", SqlDbType.Money, 8, ParameterDirection.Output, BV),
                new MSSQL.Parameter("UpVipDate", SqlDbType.DateTime, 8, ParameterDirection.Output, UpVipDate),
                new MSSQL.Parameter("LastLoginTime", SqlDbType.DateTime, 8, ParameterDirection.Output, LastLoginTime),
                new MSSQL.Parameter("LastLoginIP", SqlDbType.VarChar, 50, ParameterDirection.Output, LastLoginIP),
                new MSSQL.Parameter("LoginNum", SqlDbType.Int, 4, ParameterDirection.Output, LoginNum),
                new MSSQL.Parameter("OwnerCustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, OwnerCustomerID),
                new MSSQL.Parameter("isOwnerCustomer", SqlDbType.Bit, 1, ParameterDirection.Output, isOwnerCustomer),
                new MSSQL.Parameter("isShopAgent", SqlDbType.Bit, 1, ParameterDirection.Output, isShopAgent),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                CustomerName = System.Convert.ToString(Outputs["CustomerName"]);
            }
            catch { }

            try
            {
                CustomerTypeID = System.Convert.ToInt16(Outputs["CustomerTypeID"]);
            }
            catch { }

            try
            {
                CustomerTypeName = System.Convert.ToString(Outputs["CustomerTypeName"]);
            }
            catch { }

            try
            {
                IsAward = System.Convert.ToBoolean(Outputs["IsAward"]);
            }
            catch { }

            try
            {
                Password1 = System.Convert.ToString(Outputs["Password1"]);
            }
            catch { }

            try
            {
                Password2 = System.Convert.ToString(Outputs["Password2"]);
            }
            catch { }

            try
            {
                Tel = System.Convert.ToString(Outputs["Tel"]);
            }
            catch { }

            try
            {
                Mobile = System.Convert.ToString(Outputs["Mobile"]);
            }
            catch { }

            try
            {
                QQ = System.Convert.ToString(Outputs["QQ"]);
            }
            catch { }

            try
            {
                Email = System.Convert.ToString(Outputs["Email"]);
            }
            catch { }

            try
            {
                PostCode = System.Convert.ToString(Outputs["PostCode"]);
            }
            catch { }

            try
            {
                CityID = System.Convert.ToInt32(Outputs["CityID"]);
            }
            catch { }

            try
            {
                Province = System.Convert.ToString(Outputs["Province"]);
            }
            catch { }

            try
            {
                City = System.Convert.ToString(Outputs["City"]);
            }
            catch { }

            try
            {
                Address = System.Convert.ToString(Outputs["Address"]);
            }
            catch { }

            try
            {
                Fax = System.Convert.ToString(Outputs["Fax"]);
            }
            catch { }

            try
            {
                Other = System.Convert.ToString(Outputs["Other"]);
            }
            catch { }

            try
            {
                Sex = System.Convert.ToString(Outputs["Sex"]);
            }
            catch { }

            try
            {
                Birthday = System.Convert.ToDateTime(Outputs["Birthday"]);
            }
            catch { }

            try
            {
                CertTypeID = System.Convert.ToInt16(Outputs["CertTypeID"]);
            }
            catch { }

            try
            {
                CertTypeName = System.Convert.ToString(Outputs["CertTypeName"]);
            }
            catch { }

            try
            {
                CertNo = System.Convert.ToString(Outputs["CertNo"]);
            }
            catch { }

            try
            {
                BankTypeID = System.Convert.ToInt32(Outputs["BankTypeID"]);
            }
            catch { }

            try
            {
                BankTypeName = System.Convert.ToString(Outputs["BankTypeName"]);
            }
            catch { }

            try
            {
                BankNameDetail = System.Convert.ToString(Outputs["BankNameDetail"]);
            }
            catch { }

            try
            {
                BankCardNumber = System.Convert.ToString(Outputs["BankCardNumber"]);
            }
            catch { }

            try
            {
                BankCustName = System.Convert.ToString(Outputs["BankCustName"]);
            }
            catch { }

            try
            {
                AlipayNo = System.Convert.ToString(Outputs["AlipayNo"]);
            }
            catch { }

            try
            {
                DeptID = System.Convert.ToInt32(Outputs["DeptID"]);
            }
            catch { }

            try
            {
                DeparmenttName = System.Convert.ToString(Outputs["DeparmenttName"]);
            }
            catch { }

            try
            {
                RegisterOperID = System.Convert.ToInt64(Outputs["RegisterOperID"]);
            }
            catch { }

            try
            {
                RegisterCustomerNO = System.Convert.ToString(Outputs["RegisterCustomerNO"]);
            }
            catch { }

            try
            {
                RegisterCustomerName = System.Convert.ToString(Outputs["RegisterCustomerName"]);
            }
            catch { }

            try
            {
                RegisterDate = System.Convert.ToDateTime(Outputs["RegisterDate"]);
            }
            catch { }

            try
            {
                VerfyOperID = System.Convert.ToInt64(Outputs["VerfyOperID"]);
            }
            catch { }

            try
            {
                VerfyCustomerNO = System.Convert.ToString(Outputs["VerfyCustomerNO"]);
            }
            catch { }

            try
            {
                VerfyCustomerName = System.Convert.ToString(Outputs["VerfyCustomerName"]);
            }
            catch { }

            try
            {
                VerfyDate = System.Convert.ToDateTime(Outputs["VerfyDate"]);
            }
            catch { }

            try
            {
                Status = System.Convert.ToInt16(Outputs["Status"]);
            }
            catch { }

            try
            {
                State = System.Convert.ToString(Outputs["State"]);
            }
            catch { }

            try
            {
                Remark = System.Convert.ToString(Outputs["Remark"]);
            }
            catch { }

            try
            {
                ShopNo = System.Convert.ToString(Outputs["ShopNo"]);
            }
            catch { }

            try
            {
                ShopName = System.Convert.ToString(Outputs["ShopName"]);
            }
            catch { }

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                RegisterShopID = System.Convert.ToInt64(Outputs["RegisterShopID"]);
            }
            catch { }

            try
            {
                RegisterShopNO = System.Convert.ToString(Outputs["RegisterShopNO"]);
            }
            catch { }

            try
            {
                RegisterShopName = System.Convert.ToString(Outputs["RegisterShopName"]);
            }
            catch { }

            try
            {
                SurrogateID = System.Convert.ToInt64(Outputs["SurrogateID"]);
            }
            catch { }

            try
            {
                SurrogateNO = System.Convert.ToString(Outputs["SurrogateNO"]);
            }
            catch { }

            try
            {
                SurrogateName = System.Convert.ToString(Outputs["SurrogateName"]);
            }
            catch { }

            try
            {
                CommendID = System.Convert.ToInt64(Outputs["CommendID"]);
            }
            catch { }

            try
            {
                CommendCustomerNO = System.Convert.ToString(Outputs["CommendCustomerNO"]);
            }
            catch { }

            try
            {
                CommendCustomerName = System.Convert.ToString(Outputs["CommendCustomerName"]);
            }
            catch { }

            try
            {
                ParentID = System.Convert.ToInt64(Outputs["ParentID"]);
            }
            catch { }

            try
            {
                ParentCustomerNO = System.Convert.ToString(Outputs["ParentCustomerNO"]);
            }
            catch { }

            try
            {
                ParentCustomerName = System.Convert.ToString(Outputs["ParentCustomerName"]);
            }
            catch { }

            try
            {
                LR = System.Convert.ToInt16(Outputs["LR"]);
            }
            catch { }

            try
            {
                isLock = System.Convert.ToBoolean(Outputs["isLock"]);
            }
            catch { }

            try
            {
                isActivation = System.Convert.ToBoolean(Outputs["isActivation"]);
            }
            catch { }

            try
            {
                IsSurrogate = System.Convert.ToBoolean(Outputs["IsSurrogate"]);
            }
            catch { }

            try
            {
                Balance = System.Convert.ToDouble(Outputs["Balance"]);
            }
            catch { }

            try
            {
                Freeze = System.Convert.ToDouble(Outputs["Freeze"]);
            }
            catch { }

            try
            {
                Earning = System.Convert.ToDouble(Outputs["Earning"]);
            }
            catch { }

            try
            {
                EarningBalance = System.Convert.ToDouble(Outputs["EarningBalance"]);
            }
            catch { }

            try
            {
                EarningBalance2 = System.Convert.ToDouble(Outputs["EarningBalance2"]);
            }
            catch { }

            try
            {
                Earning2 = System.Convert.ToDouble(Outputs["Earning2"]);
            }
            catch { }

            try
            {
                Earning3 = System.Convert.ToDouble(Outputs["Earning3"]);
            }
            catch { }

            try
            {
                EarningBalance3 = System.Convert.ToDouble(Outputs["EarningBalance3"]);
            }
            catch { }

            try
            {
                PV = System.Convert.ToDouble(Outputs["PV"]);
            }
            catch { }

            try
            {
                BV = System.Convert.ToDouble(Outputs["BV"]);
            }
            catch { }

            try
            {
                UpVipDate = System.Convert.ToDateTime(Outputs["UpVipDate"]);
            }
            catch { }

            try
            {
                LastLoginTime = System.Convert.ToDateTime(Outputs["LastLoginTime"]);
            }
            catch { }

            try
            {
                LastLoginIP = System.Convert.ToString(Outputs["LastLoginIP"]);
            }
            catch { }

            try
            {
                LoginNum = System.Convert.ToInt32(Outputs["LoginNum"]);
            }
            catch { }

            try
            {
                OwnerCustomerID = System.Convert.ToInt64(Outputs["OwnerCustomerID"]);
            }
            catch { }

            try
            {
                isOwnerCustomer = System.Convert.ToBoolean(Outputs["isOwnerCustomer"]);
            }
            catch { }

            try
            {
                isShopAgent = System.Convert.ToBoolean(Outputs["isShopAgent"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Earning4(DateTime DateTime)
        {
            DataSet ds = null;

            return P_Earning4(ref ds, DateTime);
        }

        public static int P_Earning4(ref DataSet ds, DateTime DateTime)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Earning4", ref ds, ref Outputs,
                new MSSQL.Parameter("DateTime", SqlDbType.DateTime, 0, ParameterDirection.Input, DateTime)
                );

            return CallResult;
        }

        public static int P_DistillEarning5(int DistillType, long Earning5ID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_DistillEarning5(ref ds, DistillType, Earning5ID, ref ReturnDescription);
        }

        public static int P_DistillEarning5(ref DataSet ds, int DistillType, long Earning5ID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DistillEarning5", ref ds, ref Outputs,
                new MSSQL.Parameter("DistillType", SqlDbType.Int, 0, ParameterDirection.Input, DistillType),
                new MSSQL.Parameter("Earning5ID", SqlDbType.BigInt, 0, ParameterDirection.Input, Earning5ID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_CheckSales(long SalesID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckSales(ref ds, SalesID, VerfyOperID);
        }

        public static int P_Shop_CheckSales(ref DataSet ds, long SalesID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckSales", ref ds, ref Outputs,
                new MSSQL.Parameter("SalesID", SqlDbType.BigInt, 0, ParameterDirection.Input, SalesID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_DistillEarning4(int DistillType, long Earning4ID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_DistillEarning4(ref ds, DistillType, Earning4ID, ref ReturnDescription);
        }

        public static int P_DistillEarning4(ref DataSet ds, int DistillType, long Earning4ID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DistillEarning4", ref ds, ref Outputs,
                new MSSQL.Parameter("DistillType", SqlDbType.Int, 0, ParameterDirection.Input, DistillType),
                new MSSQL.Parameter("Earning4ID", SqlDbType.BigInt, 0, ParameterDirection.Input, Earning4ID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_DitillByEarning5(long CustomerID, DateTime Type)
        {
            DataSet ds = null;

            return P_DitillByEarning5(ref ds, CustomerID, Type);
        }

        public static int P_DitillByEarning5(ref DataSet ds, long CustomerID, DateTime Type)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_DitillByEarning5", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("Type", SqlDbType.DateTime, 0, ParameterDirection.Input, Type)
                );

            return CallResult;
        }

        public static int P_Shop_DelShipment_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelShipment_Master(ref ds, ID);
        }

        public static int P_Shop_DelShipment_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelShipment_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_Shop_AddSales_Detail(long SalesID, long GoodID, int Amount, double ActualPrice, string GoodNorm, string GoodColor)
        {
            DataSet ds = null;

            return P_Shop_AddSales_Detail(ref ds, SalesID, GoodID, Amount, ActualPrice, GoodNorm, GoodColor);
        }

        public static int P_Shop_AddSales_Detail(ref DataSet ds, long SalesID, long GoodID, int Amount, double ActualPrice, string GoodNorm, string GoodColor)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddSales_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("SalesID", SqlDbType.BigInt, 0, ParameterDirection.Input, SalesID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount),
                new MSSQL.Parameter("ActualPrice", SqlDbType.Float, 0, ParameterDirection.Input, ActualPrice),
                new MSSQL.Parameter("GoodNorm", SqlDbType.VarChar, 0, ParameterDirection.Input, GoodNorm),
                new MSSQL.Parameter("GoodColor", SqlDbType.VarChar, 0, ParameterDirection.Input, GoodColor)
                );

            return CallResult;
        }

        public static int P_Shop_AddSales_Master(long CustomerID, long CreateShopID, long CreateOperID, short SalesType, string Remark, ref long NowID)
        {
            DataSet ds = null;

            return P_Shop_AddSales_Master(ref ds, CustomerID, CreateShopID, CreateOperID, SalesType, Remark, ref NowID);
        }

        public static int P_Shop_AddSales_Master(ref DataSet ds, long CustomerID, long CreateShopID, long CreateOperID, short SalesType, string Remark, ref long NowID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_AddSales_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 0, ParameterDirection.Input, CustomerID),
                new MSSQL.Parameter("CreateShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateShopID),
                new MSSQL.Parameter("CreateOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, CreateOperID),
                new MSSQL.Parameter("SalesType", SqlDbType.TinyInt, 0, ParameterDirection.Input, SalesType),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("NowID", SqlDbType.BigInt, 8, ParameterDirection.Output, NowID)
                );

            try
            {
                NowID = System.Convert.ToInt64(Outputs["NowID"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_CheckShipment(long ShipmentID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckShipment(ref ds, ShipmentID, VerfyOperID);
        }

        public static int P_Shop_CheckShipment(ref DataSet ds, long ShipmentID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckShipment", ref ds, ref Outputs,
                new MSSQL.Parameter("ShipmentID", SqlDbType.BigInt, 0, ParameterDirection.Input, ShipmentID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_Shop_EditSales_Detail(long ID, long SalesID, long GoodID, int Amount)
        {
            DataSet ds = null;

            return P_Shop_EditSales_Detail(ref ds, ID, SalesID, GoodID, Amount);
        }

        public static int P_Shop_EditSales_Detail(ref DataSet ds, long ID, long SalesID, long GoodID, int Amount)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_EditSales_Detail", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID),
                new MSSQL.Parameter("SalesID", SqlDbType.BigInt, 0, ParameterDirection.Input, SalesID),
                new MSSQL.Parameter("GoodID", SqlDbType.BigInt, 0, ParameterDirection.Input, GoodID),
                new MSSQL.Parameter("Amount", SqlDbType.Int, 0, ParameterDirection.Input, Amount)
                );

            return CallResult;
        }

        public static int P_Shop_DelInventory_Master(long ID)
        {
            DataSet ds = null;

            return P_Shop_DelInventory_Master(ref ds, ID);
        }

        public static int P_Shop_DelInventory_Master(ref DataSet ds, long ID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_DelInventory_Master", ref ds, ref Outputs,
                new MSSQL.Parameter("ID", SqlDbType.BigInt, 0, ParameterDirection.Input, ID)
                );

            return CallResult;
        }

        public static int P_GetOptions(ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_GetOptions(ref ds, ref ReturnDescription);
        }

        public static int P_GetOptions(ref DataSet ds, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetOptions", ref ds, ref Outputs,
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_GetOptions2(ref double Opt_加盟金, ref double Opt_每单价格, ref double Opt_市场拓展奖, ref int Opt_1vsX, ref double Opt_1单返还货币, ref double Opt_市场拓展奖周封顶, ref double Opt_网店零售奖比例, ref double Opt_一级市场提成奖比例, ref double Opt_二级市场提成奖比例, ref double Opt_三级市场提成奖比例, ref double Opt_银店资格, ref double Opt_金店资格, ref double Opt_钻店资格, ref double Opt_银店三代管理补贴奖比例, ref double Opt_金店三代管理补贴奖比例, ref double Opt_金店六代管理补贴奖比例, ref double Opt_钻店三代管理补贴奖比例, ref double Opt_钻店六代管理补贴奖比例, ref double Opt_钻店九代管理补贴奖比例, ref double Opt_销售分红奖比例, ref double Opt_销售鼓励奖比例, ref double Opt_月最低销售业绩, ref double Opt_网站维护费, ref double Opt_税金提取比例, ref DateTime Opt_最后结算日期, ref string Opt_系统暂停原因, ref bool Opt_系统暂停, ref bool Opt_系统紧急关闭)
        {
            DataSet ds = null;

            return P_GetOptions2(ref ds, ref Opt_加盟金, ref Opt_每单价格, ref Opt_市场拓展奖, ref Opt_1vsX, ref Opt_1单返还货币, ref Opt_市场拓展奖周封顶, ref Opt_网店零售奖比例, ref Opt_一级市场提成奖比例, ref Opt_二级市场提成奖比例, ref Opt_三级市场提成奖比例, ref Opt_银店资格, ref Opt_金店资格, ref Opt_钻店资格, ref Opt_银店三代管理补贴奖比例, ref Opt_金店三代管理补贴奖比例, ref Opt_金店六代管理补贴奖比例, ref Opt_钻店三代管理补贴奖比例, ref Opt_钻店六代管理补贴奖比例, ref Opt_钻店九代管理补贴奖比例, ref Opt_销售分红奖比例, ref Opt_销售鼓励奖比例, ref Opt_月最低销售业绩, ref Opt_网站维护费, ref Opt_税金提取比例, ref Opt_最后结算日期, ref Opt_系统暂停原因, ref Opt_系统暂停, ref Opt_系统紧急关闭);
        }

        public static int P_GetOptions2(ref DataSet ds, ref double Opt_加盟金, ref double Opt_每单价格, ref double Opt_市场拓展奖, ref int Opt_1vsX, ref double Opt_1单返还货币, ref double Opt_市场拓展奖周封顶, ref double Opt_网店零售奖比例, ref double Opt_一级市场提成奖比例, ref double Opt_二级市场提成奖比例, ref double Opt_三级市场提成奖比例, ref double Opt_银店资格, ref double Opt_金店资格, ref double Opt_钻店资格, ref double Opt_银店三代管理补贴奖比例, ref double Opt_金店三代管理补贴奖比例, ref double Opt_金店六代管理补贴奖比例, ref double Opt_钻店三代管理补贴奖比例, ref double Opt_钻店六代管理补贴奖比例, ref double Opt_钻店九代管理补贴奖比例, ref double Opt_销售分红奖比例, ref double Opt_销售鼓励奖比例, ref double Opt_月最低销售业绩, ref double Opt_网站维护费, ref double Opt_税金提取比例, ref DateTime Opt_最后结算日期, ref string Opt_系统暂停原因, ref bool Opt_系统暂停, ref bool Opt_系统紧急关闭)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_GetOptions2", ref ds, ref Outputs,
                new MSSQL.Parameter("Opt_加盟金", SqlDbType.Money, 8, ParameterDirection.Output, Opt_加盟金),
                new MSSQL.Parameter("Opt_每单价格", SqlDbType.Money, 8, ParameterDirection.Output, Opt_每单价格),
                new MSSQL.Parameter("Opt_市场拓展奖", SqlDbType.Money, 8, ParameterDirection.Output, Opt_市场拓展奖),
                new MSSQL.Parameter("Opt_1vsX", SqlDbType.Int, 4, ParameterDirection.Output, Opt_1vsX),
                new MSSQL.Parameter("Opt_1单返还货币", SqlDbType.Money, 8, ParameterDirection.Output, Opt_1单返还货币),
                new MSSQL.Parameter("Opt_市场拓展奖周封顶", SqlDbType.Money, 8, ParameterDirection.Output, Opt_市场拓展奖周封顶),
                new MSSQL.Parameter("Opt_网店零售奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_网店零售奖比例),
                new MSSQL.Parameter("Opt_一级市场提成奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_一级市场提成奖比例),
                new MSSQL.Parameter("Opt_二级市场提成奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_二级市场提成奖比例),
                new MSSQL.Parameter("Opt_三级市场提成奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_三级市场提成奖比例),
                new MSSQL.Parameter("Opt_银店资格", SqlDbType.Money, 8, ParameterDirection.Output, Opt_银店资格),
                new MSSQL.Parameter("Opt_金店资格", SqlDbType.Money, 8, ParameterDirection.Output, Opt_金店资格),
                new MSSQL.Parameter("Opt_钻店资格", SqlDbType.Money, 8, ParameterDirection.Output, Opt_钻店资格),
                new MSSQL.Parameter("Opt_银店三代管理补贴奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_银店三代管理补贴奖比例),
                new MSSQL.Parameter("Opt_金店三代管理补贴奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_金店三代管理补贴奖比例),
                new MSSQL.Parameter("Opt_金店六代管理补贴奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_金店六代管理补贴奖比例),
                new MSSQL.Parameter("Opt_钻店三代管理补贴奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_钻店三代管理补贴奖比例),
                new MSSQL.Parameter("Opt_钻店六代管理补贴奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_钻店六代管理补贴奖比例),
                new MSSQL.Parameter("Opt_钻店九代管理补贴奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_钻店九代管理补贴奖比例),
                new MSSQL.Parameter("Opt_销售分红奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_销售分红奖比例),
                new MSSQL.Parameter("Opt_销售鼓励奖比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_销售鼓励奖比例),
                new MSSQL.Parameter("Opt_月最低销售业绩", SqlDbType.Money, 8, ParameterDirection.Output, Opt_月最低销售业绩),
                new MSSQL.Parameter("Opt_网站维护费", SqlDbType.Money, 8, ParameterDirection.Output, Opt_网站维护费),
                new MSSQL.Parameter("Opt_税金提取比例", SqlDbType.Float, 8, ParameterDirection.Output, Opt_税金提取比例),
                new MSSQL.Parameter("Opt_最后结算日期", SqlDbType.DateTime, 8, ParameterDirection.Output, Opt_最后结算日期),
                new MSSQL.Parameter("Opt_系统暂停原因", SqlDbType.VarChar, 100, ParameterDirection.Output, Opt_系统暂停原因),
                new MSSQL.Parameter("Opt_系统暂停", SqlDbType.Bit, 1, ParameterDirection.Output, Opt_系统暂停),
                new MSSQL.Parameter("Opt_系统紧急关闭", SqlDbType.Bit, 1, ParameterDirection.Output, Opt_系统紧急关闭)
                );

            try
            {
                Opt_加盟金 = System.Convert.ToDouble(Outputs["Opt_加盟金"]);
            }
            catch { }

            try
            {
                Opt_每单价格 = System.Convert.ToDouble(Outputs["Opt_每单价格"]);
            }
            catch { }

            try
            {
                Opt_市场拓展奖 = System.Convert.ToDouble(Outputs["Opt_市场拓展奖"]);
            }
            catch { }

            try
            {
                Opt_1vsX = System.Convert.ToInt32(Outputs["Opt_1vsX"]);
            }
            catch { }

            try
            {
                Opt_1单返还货币 = System.Convert.ToDouble(Outputs["Opt_1单返还货币"]);
            }
            catch { }

            try
            {
                Opt_市场拓展奖周封顶 = System.Convert.ToDouble(Outputs["Opt_市场拓展奖周封顶"]);
            }
            catch { }

            try
            {
                Opt_网店零售奖比例 = System.Convert.ToDouble(Outputs["Opt_网店零售奖比例"]);
            }
            catch { }

            try
            {
                Opt_一级市场提成奖比例 = System.Convert.ToDouble(Outputs["Opt_一级市场提成奖比例"]);
            }
            catch { }

            try
            {
                Opt_二级市场提成奖比例 = System.Convert.ToDouble(Outputs["Opt_二级市场提成奖比例"]);
            }
            catch { }

            try
            {
                Opt_三级市场提成奖比例 = System.Convert.ToDouble(Outputs["Opt_三级市场提成奖比例"]);
            }
            catch { }

            try
            {
                Opt_银店资格 = System.Convert.ToDouble(Outputs["Opt_银店资格"]);
            }
            catch { }

            try
            {
                Opt_金店资格 = System.Convert.ToDouble(Outputs["Opt_金店资格"]);
            }
            catch { }

            try
            {
                Opt_钻店资格 = System.Convert.ToDouble(Outputs["Opt_钻店资格"]);
            }
            catch { }

            try
            {
                Opt_银店三代管理补贴奖比例 = System.Convert.ToDouble(Outputs["Opt_银店三代管理补贴奖比例"]);
            }
            catch { }

            try
            {
                Opt_金店三代管理补贴奖比例 = System.Convert.ToDouble(Outputs["Opt_金店三代管理补贴奖比例"]);
            }
            catch { }

            try
            {
                Opt_金店六代管理补贴奖比例 = System.Convert.ToDouble(Outputs["Opt_金店六代管理补贴奖比例"]);
            }
            catch { }

            try
            {
                Opt_钻店三代管理补贴奖比例 = System.Convert.ToDouble(Outputs["Opt_钻店三代管理补贴奖比例"]);
            }
            catch { }

            try
            {
                Opt_钻店六代管理补贴奖比例 = System.Convert.ToDouble(Outputs["Opt_钻店六代管理补贴奖比例"]);
            }
            catch { }

            try
            {
                Opt_钻店九代管理补贴奖比例 = System.Convert.ToDouble(Outputs["Opt_钻店九代管理补贴奖比例"]);
            }
            catch { }

            try
            {
                Opt_销售分红奖比例 = System.Convert.ToDouble(Outputs["Opt_销售分红奖比例"]);
            }
            catch { }

            try
            {
                Opt_销售鼓励奖比例 = System.Convert.ToDouble(Outputs["Opt_销售鼓励奖比例"]);
            }
            catch { }

            try
            {
                Opt_月最低销售业绩 = System.Convert.ToDouble(Outputs["Opt_月最低销售业绩"]);
            }
            catch { }

            try
            {
                Opt_网站维护费 = System.Convert.ToDouble(Outputs["Opt_网站维护费"]);
            }
            catch { }

            try
            {
                Opt_税金提取比例 = System.Convert.ToDouble(Outputs["Opt_税金提取比例"]);
            }
            catch { }

            try
            {
                Opt_最后结算日期 = System.Convert.ToDateTime(Outputs["Opt_最后结算日期"]);
            }
            catch { }

            try
            {
                Opt_系统暂停原因 = System.Convert.ToString(Outputs["Opt_系统暂停原因"]);
            }
            catch { }

            try
            {
                Opt_系统暂停 = System.Convert.ToBoolean(Outputs["Opt_系统暂停"]);
            }
            catch { }

            try
            {
                Opt_系统紧急关闭 = System.Convert.ToBoolean(Outputs["Opt_系统紧急关闭"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_Shop_CheckInventory(long InventoryID, long VerfyOperID)
        {
            DataSet ds = null;

            return P_Shop_CheckInventory(ref ds, InventoryID, VerfyOperID);
        }

        public static int P_Shop_CheckInventory(ref DataSet ds, long InventoryID, long VerfyOperID)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Shop_CheckInventory", ref ds, ref Outputs,
                new MSSQL.Parameter("InventoryID", SqlDbType.BigInt, 0, ParameterDirection.Input, InventoryID),
                new MSSQL.Parameter("VerfyOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, VerfyOperID)
                );

            return CallResult;
        }

        public static int P_Buy(long SurrogateID, string Name, string RealityName, string Password, string Password2, string Sex, string Birthday, int CityID, string IDCardNumber, string Address, string Email, string QQ, string Telephone, string Mobile, int BankTypeID, string BankNameDetail, string BankCardNumber, int UserType, long ParentID, int LR, long CommendID, bool AutoNext, bool isActivation, long SiteID, ref long UserID, ref long ShopID, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_Buy(ref ds, SurrogateID, Name, RealityName, Password, Password2, Sex, Birthday, CityID, IDCardNumber, Address, Email, QQ, Telephone, Mobile, BankTypeID, BankNameDetail, BankCardNumber, UserType, ParentID, LR, CommendID, AutoNext, isActivation, SiteID, ref UserID, ref ShopID, ref ReturnDescription);
        }

        public static int P_Buy(ref DataSet ds, long SurrogateID, string Name, string RealityName, string Password, string Password2, string Sex, string Birthday, int CityID, string IDCardNumber, string Address, string Email, string QQ, string Telephone, string Mobile, int BankTypeID, string BankNameDetail, string BankCardNumber, int UserType, long ParentID, int LR, long CommendID, bool AutoNext, bool isActivation, long SiteID, ref long UserID, ref long ShopID, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_Buy", ref ds, ref Outputs,
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("Name", SqlDbType.VarChar, 0, ParameterDirection.Input, Name),
                new MSSQL.Parameter("RealityName", SqlDbType.VarChar, 0, ParameterDirection.Input, RealityName),
                new MSSQL.Parameter("Password", SqlDbType.VarChar, 0, ParameterDirection.Input, Password),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 0, ParameterDirection.Input, Password2),
                new MSSQL.Parameter("Sex", SqlDbType.Char, 0, ParameterDirection.Input, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.VarChar, 0, ParameterDirection.Input, Birthday),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 0, ParameterDirection.Input, CityID),
                new MSSQL.Parameter("IDCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, IDCardNumber),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 0, ParameterDirection.Input, Address),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 0, ParameterDirection.Input, Email),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 0, ParameterDirection.Input, QQ),
                new MSSQL.Parameter("Telephone", SqlDbType.VarChar, 0, ParameterDirection.Input, Telephone),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 0, ParameterDirection.Input, Mobile),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 0, ParameterDirection.Input, BankTypeID),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 0, ParameterDirection.Input, BankNameDetail),
                new MSSQL.Parameter("BankCardNumber", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNumber),
                new MSSQL.Parameter("UserType", SqlDbType.Int, 0, ParameterDirection.Input, UserType),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 0, ParameterDirection.Input, ParentID),
                new MSSQL.Parameter("LR", SqlDbType.Int, 0, ParameterDirection.Input, LR),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 0, ParameterDirection.Input, CommendID),
                new MSSQL.Parameter("AutoNext", SqlDbType.Bit, 0, ParameterDirection.Input, AutoNext),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 0, ParameterDirection.Input, isActivation),
                new MSSQL.Parameter("SiteID", SqlDbType.BigInt, 0, ParameterDirection.Input, SiteID),
                new MSSQL.Parameter("UserID", SqlDbType.BigInt, 8, ParameterDirection.Output, UserID),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                UserID = System.Convert.ToInt64(Outputs["UserID"]);
            }
            catch { }

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }

        public static int P_ShopAdd(string CustomerNo, string CustomerName, int CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNo, string BankCustName, int DeptID, long RegisterOperID, string Remark, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, int Location, bool AutoNext, bool isLock, bool isActivation, bool IsSurrogate, ref long ShopID, ref long CustomerID, ref string NewWebSiteURL, ref string ReturnDescription)
        {
            DataSet ds = null;

            return P_ShopAdd(ref ds, CustomerNo, CustomerName, CustomerTypeID, Password1, Password2, Tel, Mobile, QQ, Email, PostCode, CityID, Address, Fax, Other, Sex, Birthday, CertTypeID, CertNo, BankTypeID, BankNameDetail, BankCardNo, BankCustName, DeptID, RegisterOperID, Remark, RegisterShopID, SurrogateID, CommendID, ParentID, Location, AutoNext, isLock, isActivation, IsSurrogate, ref ShopID, ref CustomerID, ref NewWebSiteURL, ref ReturnDescription);
        }

        public static int P_ShopAdd(ref DataSet ds, string CustomerNo, string CustomerName, int CustomerTypeID, string Password1, string Password2, string Tel, string Mobile, string QQ, string Email, string PostCode, int CityID, string Address, string Fax, string Other, string Sex, DateTime Birthday, short CertTypeID, string CertNo, int BankTypeID, string BankNameDetail, string BankCardNo, string BankCustName, int DeptID, long RegisterOperID, string Remark, long RegisterShopID, long SurrogateID, long CommendID, long ParentID, int Location, bool AutoNext, bool isLock, bool isActivation, bool IsSurrogate, ref long ShopID, ref long CustomerID, ref string NewWebSiteURL, ref string ReturnDescription)
        {
            MSSQL.OutputParameter Outputs = new MSSQL.OutputParameter();

            int CallResult = MSSQL.ExecuteStoredProcedureWithQuery("P_ShopAdd", ref ds, ref Outputs,
                new MSSQL.Parameter("CustomerNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerNo),
                new MSSQL.Parameter("CustomerName", SqlDbType.VarChar, 0, ParameterDirection.Input, CustomerName),
                new MSSQL.Parameter("CustomerTypeID", SqlDbType.Int, 0, ParameterDirection.Input, CustomerTypeID),
                new MSSQL.Parameter("Password1", SqlDbType.VarChar, 0, ParameterDirection.Input, Password1),
                new MSSQL.Parameter("Password2", SqlDbType.VarChar, 0, ParameterDirection.Input, Password2),
                new MSSQL.Parameter("Tel", SqlDbType.VarChar, 0, ParameterDirection.Input, Tel),
                new MSSQL.Parameter("Mobile", SqlDbType.VarChar, 0, ParameterDirection.Input, Mobile),
                new MSSQL.Parameter("QQ", SqlDbType.VarChar, 0, ParameterDirection.Input, QQ),
                new MSSQL.Parameter("Email", SqlDbType.VarChar, 0, ParameterDirection.Input, Email),
                new MSSQL.Parameter("PostCode", SqlDbType.VarChar, 0, ParameterDirection.Input, PostCode),
                new MSSQL.Parameter("CityID", SqlDbType.Int, 0, ParameterDirection.Input, CityID),
                new MSSQL.Parameter("Address", SqlDbType.VarChar, 0, ParameterDirection.Input, Address),
                new MSSQL.Parameter("Fax", SqlDbType.VarChar, 0, ParameterDirection.Input, Fax),
                new MSSQL.Parameter("Other", SqlDbType.VarChar, 0, ParameterDirection.Input, Other),
                new MSSQL.Parameter("Sex", SqlDbType.VarChar, 0, ParameterDirection.Input, Sex),
                new MSSQL.Parameter("Birthday", SqlDbType.DateTime, 0, ParameterDirection.Input, Birthday),
                new MSSQL.Parameter("CertTypeID", SqlDbType.TinyInt, 0, ParameterDirection.Input, CertTypeID),
                new MSSQL.Parameter("CertNo", SqlDbType.VarChar, 0, ParameterDirection.Input, CertNo),
                new MSSQL.Parameter("BankTypeID", SqlDbType.Int, 0, ParameterDirection.Input, BankTypeID),
                new MSSQL.Parameter("BankNameDetail", SqlDbType.VarChar, 0, ParameterDirection.Input, BankNameDetail),
                new MSSQL.Parameter("BankCardNo", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCardNo),
                new MSSQL.Parameter("BankCustName", SqlDbType.VarChar, 0, ParameterDirection.Input, BankCustName),
                new MSSQL.Parameter("DeptID", SqlDbType.Int, 0, ParameterDirection.Input, DeptID),
                new MSSQL.Parameter("RegisterOperID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterOperID),
                new MSSQL.Parameter("Remark", SqlDbType.VarChar, 0, ParameterDirection.Input, Remark),
                new MSSQL.Parameter("RegisterShopID", SqlDbType.BigInt, 0, ParameterDirection.Input, RegisterShopID),
                new MSSQL.Parameter("SurrogateID", SqlDbType.BigInt, 0, ParameterDirection.Input, SurrogateID),
                new MSSQL.Parameter("CommendID", SqlDbType.BigInt, 0, ParameterDirection.Input, CommendID),
                new MSSQL.Parameter("ParentID", SqlDbType.BigInt, 0, ParameterDirection.Input, ParentID),
                new MSSQL.Parameter("Location", SqlDbType.Int, 0, ParameterDirection.Input, Location),
                new MSSQL.Parameter("AutoNext", SqlDbType.Bit, 0, ParameterDirection.Input, AutoNext),
                new MSSQL.Parameter("isLock", SqlDbType.Bit, 0, ParameterDirection.Input, isLock),
                new MSSQL.Parameter("isActivation", SqlDbType.Bit, 0, ParameterDirection.Input, isActivation),
                new MSSQL.Parameter("IsSurrogate", SqlDbType.Bit, 0, ParameterDirection.Input, IsSurrogate),
                new MSSQL.Parameter("ShopID", SqlDbType.BigInt, 8, ParameterDirection.Output, ShopID),
                new MSSQL.Parameter("CustomerID", SqlDbType.BigInt, 8, ParameterDirection.Output, CustomerID),
                new MSSQL.Parameter("NewWebSiteURL", SqlDbType.VarChar, 1000, ParameterDirection.Output, NewWebSiteURL),
                new MSSQL.Parameter("ReturnDescription", SqlDbType.VarChar, 100, ParameterDirection.Output, ReturnDescription)
                );

            try
            {
                ShopID = System.Convert.ToInt64(Outputs["ShopID"]);
            }
            catch { }

            try
            {
                CustomerID = System.Convert.ToInt64(Outputs["CustomerID"]);
            }
            catch { }

            try
            {
                NewWebSiteURL = System.Convert.ToString(Outputs["NewWebSiteURL"]);
            }
            catch { }

            try
            {
                ReturnDescription = System.Convert.ToString(Outputs["ReturnDescription"]);
            }
            catch { }

            return CallResult;
        }
    }
}
